[Bug tree-optimization/63947] New: Wrong assembly code generation
ishiura-compiler at ml dot kwansei.ac.jp
gcc-bugzilla@gcc.gnu.org
Wed Nov 19 07:22:00 GMT 2014
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63947
Bug ID: 63947
Summary: Wrong assembly code generation
Product: gcc
Version: 4.9.2
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: tree-optimization
Assignee: unassigned at gcc dot gnu.org
Reporter: ishiura-compiler at ml dot kwansei.ac.jp
GCC 4.9.2 for x86_64 miscompiles the following code with optimize option -Os.
$ cat error.c
unsigned int a = 0U;
int t = 0;
int main (void)
{
int b = 0;
volatile int c = 0;
long double d = 1.0L;
int e = 0;
t = (((b+e)/d)-(a>(c+a)));
return 0;
}
$ x86_64-unknown-linux-gnu-gcc-4.9.2 error.c -Os
/tmp/ccjhNwLd.s: Assembler messages:
/tmp/ccjhNwLd.s:18: Error: no such instruction: `fcmovnc %st(1),%st'
$ x86_64-unknown-linux-gnu-gcc-4.9.2 -v
Using built-in specs.
COLLECT_GCC=x86_64-unknown-linux-gnu-gcc-4.9.2
COLLECT_LTO_WRAPPER=/usr/local/x86_64-tools/gcc-4.9.2/libexec/gcc/x86_64-unknown-linux-gnu/4.9.2/lto-wrapper
Target: x86_64-unknown-linux-gnu
Configured with: ../configure --prefix=/usr/local/x86_64-tools/gcc-4.9.2/
--with-gmp=/usr/local/gmp-5.0.5/ --with-mpfr=/usr/local/mpfr-3.1.0/
--with-mpc=/usr/local/mpc-0.9/ --disable-multilib --disable-nls
--enable-languages=c
Thread model: posix
gcc version 4.9.2 (GCC)
More information about the Gcc-bugs
mailing list