http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53676
Bug #: 53676 Summary: [4.7/4.8 regression] constant folding regression, shown as slowdown as measured by Adobe's C++Benchmark Classification: Unclassified Product: gcc Version: 4.7.1 Status: UNCONFIRMED Severity: major Priority: P3 Component: middle-end AssignedTo: unassig...@gcc.gnu.org ReportedBy: m...@use.net The attached ZIP contains two binaries and preprocessor output files, based on a subset of a test in Adobe's C++Benchmark suite. All GCC versions I tested prior to 4.7 do the folding correctly. I tried using Ofast and other tricks to workaround this new regression to no avail. -rw-r--r-- 1 mhargett users 143573 Jun 14 15:31 int8_folding_test.gcc47.i mhargett@chert:~/src/C++Benchmarks-gcc47-google-fast$ ./int8_folding_test-gcc46 ./int8_folding_test-gcc46 test description absolute operations ratio with number time per second test0 0 "int8_t constant" 0.00 sec inf M -nan Total absolute time for int8_t simple constant folding: 0.00 sec mhargett@chert:~/src/C++Benchmarks-gcc47-google-fast$ ./int8_folding_test-gcc47 ./int8_folding_test-gcc47 test description absolute operations ratio with number time per second test0 0 "int8_t constant" 0.69 sec 2318.84 M 1.00 Total absolute time for int8_t simple constant folding: 0.69 sec