http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46805
Summary: ICE: SIGSEGV in optab_for_tree_code (optabs.c:407) with -O -fno-tree-scev-cprop -ftree-vectorize Product: gcc Version: 4.6.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: tree-optimization AssignedTo: unassig...@gcc.gnu.org ReportedBy: zso...@seznam.cz Created attachment 22635 --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=22635 reduced testcase valgrind output: $ gcc -O -fno-tree-scev-cprop -ftree-vectorize pr46805.go ==28234== Conditional jump or move depends on uninitialised value(s) ==28234== at 0x595C61: Lex::require_line() (lex.cc:501) ==28234== by 0x597E1A: Lex::next_token() (lex.cc:544) ==28234== by 0x598532: Parse::peek_token() (parse.cc:64) ==28234== by 0x59A08A: Parse::package_clause() (parse.cc:4544) ==28234== by 0x5A6F7D: Parse::program() (parse.cc:4624) ==28234== by 0x5717AC: go_parse_input_files (go.cc:82) ==28234== by 0x91B4F7: toplev_main (toplev.c:579) ==28234== by 0x65EABBC: (below main) (in /lib64/libc-2.11.2.so) ==28234== Uninitialised value was created by a stack allocation ==28234== at 0x56E720: go_langhook_parse_file (go-lang.c:222) ==28234== ==28234== Invalid read of size 2 ==28234== at 0x8153C0: optab_for_tree_code (optabs.c:407) ==28234== by 0xA56359: supportable_widening_operation (tree-vect-stmts.c:5521) ==28234== by 0xA56B45: vectorizable_type_promotion (tree-vect-stmts.c:3177) ==28234== by 0xA596E3: vect_analyze_stmt (tree-vect-stmts.c:4697) ==28234== by 0xA6522E: vect_analyze_loop (tree-vect-loop.c:1249) ==28234== by 0xA71968: vectorize_loops (tree-vectorizer.c:199) ==28234== by 0x8316FE: execute_one_pass (passes.c:1553) ==28234== by 0x8319C4: execute_pass_list (passes.c:1608) ==28234== by 0x8319D6: execute_pass_list (passes.c:1609) ==28234== by 0x8319D6: execute_pass_list (passes.c:1609) ==28234== by 0x971B45: tree_rest_of_compilation (tree-optimize.c:422) ==28234== by 0xB374E1: cgraph_expand_function (cgraphunit.c:1508) ==28234== by 0xB39AB9: cgraph_optimize (cgraphunit.c:1567) ==28234== by 0xB3A039: cgraph_finalize_compilation_unit (cgraphunit.c:1031) ==28234== by 0x57B97B: Gogo::write_globals() (gogo-tree.cc:825) ==28234== by 0x91B535: toplev_main (toplev.c:591) ==28234== by 0x65EABBC: (below main) (in /lib64/libc-2.11.2.so) ==28234== Address 0x0 is not stack'd, malloc'd or (recently) free'd ==28234== pr46805.go: In function 'main.main': pr46805.go:3:1: internal compiler error: Segmentation fault Please submit a full bug report, with preprocessed source if appropriate. See <http://gcc.gnu.org/bugs.html> for instructions. The first failure is most likely unrelated, similiar problems can be seen for other frontends as well. Tested revisions: r167453 - crash