CVS Update: xc (branch: trunk)
eta at lclark.edu
Fri Oct 29 00:34:56 PDT 2004
On Thu, 2004-10-28 at 21:36, Adam Jackson wrote:
> On Wednesday 27 October 2004 10:31, Thomas Winischhofer wrote:
> > Log message:
> > SiS driver: Enhanced memcpy() stuff; added optimized memcpy() for AMD64
> > (AMD64 code is entirely untested yet - anybody?)
> This breaks the build when the driver is built with -fPIC (the default for
> sis_memcpy.c: In function `SiS_builtin_memcp2':
> sis_memcpy.c:400: warning: string length `682' is greater than the length
> `509'ISO C89 compilers are required to support
> sis_memcpy.c: In function `taketime':
> sis_memcpy.c:500: error: PIC register `ebx' clobbered in `asm'
> make: *** [sis_memcpy.o] Error 1
> The offending code:
> __asm__ volatile (
> " cpuid\n"
> " .byte 0x0f, 0x31\n"
> "=a" (eax)
> "ebx", "ecx", "edx", "cc");
The solution to this problem as far as I found before was just to save
and restore ebx inside of the asm statement.
Eric Anholt eta at lclark.edu
http://people.freebsd.org/~anholt/ anholt at FreeBSD.org
More information about the xorg