diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2013-01-24 22:02:30 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2013-01-24 22:02:30 (GMT) |
commit | ee29bbd769ed711e5e7faa7c838d23a8092cc3d1 (patch) | |
tree | 83159109dbd353a085c20effc6733dfebf3bae44 | |
parent | 433da60a3a3bf82e99f406ea5799050ed97af6b8 (diff) | |
parent | c2c02010919d5fc1728515198b3a49624fb48cf2 (diff) | |
download | tcl-ee29bbd769ed711e5e7faa7c838d23a8092cc3d1.zip tcl-ee29bbd769ed711e5e7faa7c838d23a8092cc3d1.tar.gz tcl-ee29bbd769ed711e5e7faa7c838d23a8092cc3d1.tar.bz2 |
new version of cpuid, which doesn't use the edi register any more. Hopefully that works better on some Darwin.
-rw-r--r-- | unix/tclUnixCompat.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/unix/tclUnixCompat.c b/unix/tclUnixCompat.c index e201018..c1e1075 100644 --- a/unix/tclUnixCompat.c +++ b/unix/tclUnixCompat.c @@ -995,12 +995,11 @@ TclWinCPUID( /* See: <http://en.wikipedia.org/wiki/CPUID> */ #if defined(HAVE_CPUID) - __asm__ __volatile__("mov %%ebx, %%edi \n\t" /* save %ebx */ + __asm__ __volatile__("mov %%ebx, %%esi \n\t" /* save %ebx */ "cpuid \n\t" - "mov %%ebx, %%esi \n\t" /* save what cpuid just put in %ebx */ - "mov %%edi, %%ebx \n\t" /* restore the old %ebx */ + "xchg %%esi, %%ebx \n\t" /* restore the old %ebx */ : "=a"(regsPtr[0]), "=S"(regsPtr[1]), "=c"(regsPtr[2]), "=d"(regsPtr[3]) - : "a"(index) : "edi"); + : "a"(index)); status = TCL_OK; #endif return status; |