------- Comment #4 from pinskia at gcc dot gnu dot org  2005-12-08 00:49 -------
Can you try -ffloat-store or do the following:
On Linux/ix86 we use long double precision for evaluation of floating point
variables. This can lead to different values than the expected values. I'm
experimenting on the tests for cfg-branch with a small shared library that is
preloaded. 

The complete code is below, I compiled it with gcc -Wall -O2 -shared -o
libchange-precission.so change-precission.c and set LD_PRELOAD to this library. 

extern void change_precission (void) __attribute__ ((constructor));

void
change_precission (void)
{
  unsigned int cw = 0x27f;

  __asm__ volatile ("fldcw %0" :: "m" (*&cw));
}


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25303

Reply via email to