http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55331



             Bug #: 55331

           Summary: [4.6/4.7/4.8 Regression] ICE: SIGSEGV in

                    substitute_and_fold with -O2 -fno-tree-fre

    Classification: Unclassified

           Product: gcc

           Version: 4.8.0

            Status: UNCONFIRMED

          Severity: normal

          Priority: P3

         Component: middle-end

        AssignedTo: unassig...@gcc.gnu.org

        ReportedBy: zso...@seznam.cz





Created attachment 28691

  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=28691

autoreduced testcase



Compiler output:

$ gcc -O2 -fno-tree-fre testcase-min7.ii -wrapper

valgrind,-q,--num-callers=40,--track-origins=yes -w

==4620== Invalid read of size 1

==4620==    at 0xCEBDBD: substitute_and_fold(tree_node* (*)(tree_node*), bool

(*)(gimple_stmt_iterator*), bool) (gimple.h:1146)

==4620==    by 0xC857C2: execute_copy_prop() (tree-ssa-copy.c:772)

==4620==    by 0xADBB7A: execute_one_pass(opt_pass*) (passes.c:2339)

==4620==    by 0xADBF94: execute_pass_list(opt_pass*) (passes.c:2400)

==4620==    by 0xADBFA6: execute_pass_list(opt_pass*) (passes.c:2401)

==4620==    by 0xADBFA6: execute_pass_list(opt_pass*) (passes.c:2401)

==4620==    by 0x85E4F1: expand_function(cgraph_node*) (cgraphunit.c:1643)

==4620==    by 0x8602A6: compile() (cgraphunit.c:1747)

==4620==    by 0x860949: finalize_compilation_unit() (cgraphunit.c:2122)

==4620==    by 0x67717E: cp_write_global_declarations() (decl2.c:4287)

==4620==    by 0xBC527C: compile_file() (toplev.c:559)

==4620==    by 0xBC7139: toplev_main(int, char**) (toplev.c:1881)

==4620==    by 0x5A364BC: (below main) (in /lib64/libc-2.15.so)

==4620==  Address 0x0 is not stack'd, malloc'd or (recently) free'd

==4620== 

testcase-min7.ii: In function 'void test01()':

testcase-min7.ii:253:1: internal compiler error: Segmentation fault

 test01 ()

 ^

Please submit a full bug report,

with preprocessed source if appropriate.

See <http://gcc.gnu.org/bugs.html> for instructions.





Tested revisions:

r193495 - crash

4.7 r191640 - crash

4.6 r191640 - crash

4.5 r191640 - OK

Reply via email to