Porting glibc to MIPS I noticed that the initial contents of the fpu
control word doesn't seem to be right (at least on the machines I've
tried - one with a normal MIPS 2.2.13 and one with 2.2.15 and the
MIPS/Algorithmics patches (including FPU emulator).
The appended small test program should return a 0 (that's the desired
value by glibc for full ISO C99 support) - but it seems to be set to
0x600.
Could the kernel folks fix this, please? I grepped through the sources
and didn't find a place where the FPU gets initialised.:-(
Thanks,
Andreas
P.S. Here's the test program:
#include <stdlib.h>
#define _FPU_GETCW(cw) __asm__ ("cfc1 %0,$31" : "=r" (cw) : )
#define _FPU_SETCW(cw) __asm__ ("ctc1 %0,$31" : : "r" (cw))
int
main (void)
{
int fpucw;
_FPU_GETCW (fpucw);
printf ("%x %d\n", fpucw, fpucw);
return 0;
}
--
Andreas Jaeger
SuSE Labs aj@suse.de
private aj@arthur.inka.de
|