From e45f0ec9e2734d7c0aee2e1e6baab7ec4ceab138 Mon Sep 17 00:00:00 2001 From: John Benediktsson <mrjbq7@gmail.com> Date: Wed, 19 Sep 2012 10:41:54 -0700 Subject: [PATCH] cpu.x86.features: temporary fix for bootstrap issue. --- basis/cpu/x86/features/features.factor | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/basis/cpu/x86/features/features.factor b/basis/cpu/x86/features/features.factor index 89168e6a5a..0206d0431a 100644 --- a/basis/cpu/x86/features/features.factor +++ b/basis/cpu/x86/features/features.factor @@ -104,7 +104,15 @@ HOOK: (cpuid) cpu ( n regs -- ) cpu-extended-model cpu-model [ >hex ] bi@ ] "" append-outputs-as ; -: popcnt? ( -- ? ) 1 cpuid third 23 bit? ; +: popcnt? ( -- ? ) + bool { } cdecl [ + return-reg 1 MOV + CPUID + return-reg dup XOR + ECX 23 BT + return-reg SETB + ] alien-assembly ; + : tscdeadline? ( -- ? ) 1 cpuid third 24 bit? ; : aes? ( -- ? ) 1 cpuid third 25 bit? ; : xsave? ( -- ? ) 1 cpuid third 26 bit? ;