https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63288
--- Comment #1 from Zdenek Sojka <zsojka at seznam dot cz> --- The original testcase also fails with a very different set of flags: $ gcc -Os -fno-if-conversion -fsched2-use-superblocks --param=tracer-min-branch-probability=14 20140326-1.i $ valgrind -q ./a.out ==8525== Invalid read of size 1 ==8525== at 0x40043A: main (in /home/smatz/Downloads/xx/a.out) ==8525== Address 0xfff01f9e6 is not stack'd, malloc'd or (recently) free'd ==8525== ==8525== ==8525== Process terminating with default action of signal 11 (SIGSEGV) ==8525== Access not within mapped region at address 0xFFF01F9E6 ==8525== at 0x40043A: main (in /home/smatz/Downloads/xx/a.out) ==8525== If you believe this happened as a result of a stack ==8525== overflow in your program's main thread (unlikely but ==8525== possible), you can try to increase the size of the ==8525== main thread stack using the --main-stacksize= flag. ==8525== The main thread stack size used in this run was 8388608. Segmentation fault