diff options
author | José Fonseca <jfonseca@vmware.com> | 2009-10-09 13:22:42 +0100 |
---|---|---|
committer | José Fonseca <jfonseca@vmware.com> | 2009-10-09 13:25:16 +0100 |
commit | 00ffef383c62ca6cd0d5687539dc45fecfbefeec (patch) | |
tree | fe3d34da33ace562889bb442c07ba2d9626f66d8 /src/gallium/auxiliary/util | |
parent | c4d54b62f5491dbec9930563209639f8fb7dcf2e (diff) |
util: Force ESI register for cpuid's ebx result.
Fixes a segfault and better code. Unfortunately using an arbitrary
register ("=r") causes the gcc to abort when the code is optimized saying
it can't satisfy the constraint. Setting seems to do the trick.
Diffstat (limited to 'src/gallium/auxiliary/util')
-rw-r--r-- | src/gallium/auxiliary/util/u_cpu_detect.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gallium/auxiliary/util/u_cpu_detect.c b/src/gallium/auxiliary/util/u_cpu_detect.c index 70ce25cfcf..ded361ce70 100644 --- a/src/gallium/auxiliary/util/u_cpu_detect.c +++ b/src/gallium/auxiliary/util/u_cpu_detect.c @@ -346,7 +346,7 @@ cpuid(uint32_t ax, uint32_t *p) "cpuid\n\t" "xchgl %%ebx, %1" : "=a" (p[0]), - "=m" (p[1]), + "=S" (p[1]), "=c" (p[2]), "=d" (p[3]) : "0" (ax) |