if the compiler has the remainder bug... yes ??

Could someone explain what this "remainder bug" is ?
. . . checking the binary format of C++ long doubles... IEEE754 Quad Precision checking whether C++ provides exact output for long doubles... no checking whether the C++ compiler supports flexible arrays... yes checking whether the IEEE inexact flag is supported in C++... no checking if the compiler has the remainder bug... yes checking whether the C++ compiler supports __attribute__ ((weak))... yes checking for fenv.h... (cached) yes checking for ieeefp.h... (cached) yes checking getopt.h usability... no checking getopt.h presence... no checking for getopt.h... no . . .

On 12/11/10 00:07, Dennis Clarke wrote:
Could someone explain what this "remainder bug" is ?
. . . checking the binary format of C++ long doubles... IEEE754 Quad Precision checking whether C++ provides exact output for long doubles... no checking whether the C++ compiler supports flexible arrays... yes checking whether the IEEE inexact flag is supported in C++... no checking if the compiler has the remainder bug... yes checking whether the C++ compiler supports __attribute__ ((weak))... yes checking for fenv.h... (cached) yes checking for ieeefp.h... (cached) yes checking getopt.h usability... no checking getopt.h presence... no checking for getopt.h... no . . .
It is a bug whereby the compiler miscompiles the remainder expression in a way that causes INT_MIN % -1 to yield a SIGFPE on CPUs of the i386 family.
participants (2)
-
Dennis Clarke
-
Roberto Bagnara