Merge pull request #766 from rhc54/topic/hwloc
Update x86_32 cpuid assembly code.
Этот коммит содержится в:
Коммит
c6cc1a9707
@ -72,14 +72,11 @@ static __hwloc_inline void hwloc_x86_cpuid(unsigned *eax, unsigned *ebx, unsigne
|
|||||||
: "+a" (*eax), "=m" (*ebx), "=&r"(sav_rbx),
|
: "+a" (*eax), "=m" (*ebx), "=&r"(sav_rbx),
|
||||||
"+c" (*ecx), "=&d" (*edx));
|
"+c" (*ecx), "=&d" (*edx));
|
||||||
#elif defined(HWLOC_X86_32_ARCH)
|
#elif defined(HWLOC_X86_32_ARCH)
|
||||||
unsigned long sav_ebx;
|
|
||||||
__asm__(
|
__asm__(
|
||||||
"mov %%ebx,%2\n\t"
|
"mov %%ebx,%1\n\t"
|
||||||
"cpuid\n\t"
|
"cpuid\n\t"
|
||||||
"xchg %2,%%ebx\n\t"
|
"xchg %%ebx,%1\n\t"
|
||||||
"movl %k2,%1\n\t"
|
: "+a" (*eax), "=SD" (*ebx), "+c" (*ecx), "=d" (*edx));
|
||||||
: "+a" (*eax), "=m" (*ebx), "=&r"(sav_ebx),
|
|
||||||
"+c" (*ecx), "=&d" (*edx));
|
|
||||||
#else
|
#else
|
||||||
#error unknown architecture
|
#error unknown architecture
|
||||||
#endif
|
#endif
|
||||||
|
Загрузка…
Ссылка в новой задаче
Block a user