Mercurial > sdl-ios-xcode
comparison src/cpuinfo/SDL_cpuinfo.c @ 4245:0319c84d274d SDL-1.2
Fixed 32-bit build
author | Sam Lantinga <slouken@libsdl.org> |
---|---|
date | Sat, 26 Sep 2009 21:38:07 +0000 |
parents | fa62bede8038 |
children | ca91f36ef3de |
comparison
equal
deleted
inserted
replaced
4244:8fc98498e4f0 | 4245:0319c84d274d |
---|---|
159 " movl %%edx,%0 \n" | 159 " movl %%edx,%0 \n" |
160 "1: \n" | 160 "1: \n" |
161 " movl %%edi,%%ebx\n" | 161 " movl %%edi,%%ebx\n" |
162 : "=m" (features) | 162 : "=m" (features) |
163 : | 163 : |
164 : "%eax", "%ebx", "%ecx", "%edx", "%edi" | 164 : "%eax", "%ecx", "%edx", "%edi" |
165 ); | 165 ); |
166 #elif defined(__GNUC__) && defined(__x86_64__) | 166 #elif defined(__GNUC__) && defined(__x86_64__) |
167 __asm__ ( | 167 __asm__ ( |
168 " movq %%rbx,%%rdi\n" | 168 " movq %%rbx,%%rdi\n" |
169 " xorl %%eax,%%eax # Set up for CPUID instruction \n" | 169 " xorl %%eax,%%eax # Set up for CPUID instruction \n" |
228 " movl %%edx,%0 \n" | 228 " movl %%edx,%0 \n" |
229 "1: \n" | 229 "1: \n" |
230 " movl %%edi,%%ebx\n" | 230 " movl %%edi,%%ebx\n" |
231 : "=m" (features) | 231 : "=m" (features) |
232 : | 232 : |
233 : "%eax", "%ebx", "%ecx", "%edx", "%edi" | 233 : "%eax", "%ecx", "%edx", "%edi" |
234 ); | 234 ); |
235 #elif defined(__GNUC__) && defined (__x86_64__) | 235 #elif defined(__GNUC__) && defined (__x86_64__) |
236 __asm__ ( | 236 __asm__ ( |
237 " movq %%rbx,%%rdi\n" | 237 " movq %%rbx,%%rdi\n" |
238 " movl $0x80000000,%%eax # Query for extended functions \n" | 238 " movl $0x80000000,%%eax # Query for extended functions \n" |