[Bug target/63408] [4.9/5/6 regression] GCC emits incorrect fixed->fp conversion instruction on Cortex-M4 target

2015-06-23 Thread itay at phobotic dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63408 --- Comment #10 from Itay Perl --- A few examples: a=100, b=0x7fff -O0: 0.0 -O3: 200.0 a=0, b=0x7fff/100.0f -O0: -1.0 -O3: 1.0 a=0, b=-0x7fff/100.0f -O0: 1.0 -O3: -1.0 Replacing vfma with vfms sounds correct to

[Bug target/63408] [4.8/4.9/5/6 regression] GCC emits incorrect fixed->fp conversion instruction on Cortex-M4 target

2015-06-21 Thread itay at phobotic dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63408 --- Comment #7 from Itay Perl --- Any news? This bug still prevents us from compiling our code with optimizations. Thanks.

[Bug target/63408] GCC emits incorrect FMA instruction on Cortex-M4 target

2014-09-29 Thread itay at phobotic dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63408 --- Comment #2 from Itay Perl --- Yes, I am certain. 1. Replacing the minus sign with a plus sign results in the same code (including the constant) 2. >>> struct.unpack('I', struct.pack('f', 100))[0] 1120403456

[Bug target/63408] New: GCC emits incorrect FMA instruction

2014-09-29 Thread itay at phobotic dot com
Assignee: unassigned at gcc dot gnu.org Reporter: itay at phobotic dot com When compiling the following function float f(float a, int b) { return a - (((float)b / 0x7fff) * 100); } with the following command-line options arm-none-eabi-gcc -O2 -mthumb -mfpu=fpv4-sp-d16