--- bench/benchmarks.c +++ bench/benchmarks.c @@ -14,7 +14,10 @@ return; TIME(asm volatile("int $0x80" :"=a" (ret) :"0" (__NR_getppid)), "int 0x80"); - TIME(asm volatile("cpuid": : :"ax", "dx", "cx", "bx"), "cpuid"); + TIME(asm volatile("movl %%ebx,%%edi\n" + "cpuid\n" + "movl %%edi,%%ebx\n" + : : :"%eax", "%edx", "%ecx", "%edi"), "cpuid"); TIME(asm volatile("addl $1,0(%esp)"), "addl"); TIME(asm volatile("lock ; addl $1,0(%esp)"), "locked add");