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

             Bug #: 51928
           Summary: ICE: SIGSEGV in lookup_fnfields_idx_nolazy
                    (search.c:1384) with -fgnu-tm on invalid code
    Classification: Unclassified
           Product: gcc
           Version: 4.7.0
            Status: UNCONFIRMED
          Severity: minor
          Priority: P3
         Component: middle-end
        AssignedTo: unassig...@gcc.gnu.org
        ReportedBy: zso...@seznam.cz
              Host: x86_64-pc-linux-gnu
            Target: x86_64-pc-linux-gnu


Created attachment 26400
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=26400
preprocessed source (testsuite/g++.dg/parse/crash54.C)

Compiler output:
$ gcc -fgnu-tm crash54.ii
==30972== Invalid read of size 1
==30972==    at 0x6E45BD: lookup_fnfields_idx_nolazy(tree_node*, tree_node*)
(search.c:1384)
==30972==    by 0x6E833F: look_for_overrides_here(tree_node*, tree_node*)
(search.c:2026)
==30972==    by 0x634E10: look_for_tm_attr_overrides(tree_node*, tree_node*)
(class.c:4335)
==30972==    by 0x65149B: finish_struct_1(tree_node*) (class.c:4355)
==30972==    by 0x6533EC: finish_struct(tree_node*, tree_node*) (class.c:6215)
==30972==    by 0x67F0FE: cp_parser_type_specifier(cp_parser*, int,
cp_decl_specifier_seq*, bool, int*, bool*) (parser.c:17977)
==30972==    by 0x6930CF: cp_parser_decl_specifier_seq(cp_parser*, int,
cp_decl_specifier_seq*, int*) (parser.c:10701)
==30972==    by 0x695A56: cp_parser_simple_declaration(cp_parser*, bool,
tree_node**) (parser.c:10351)
==30972==    by 0x69C187: cp_parser_block_declaration(cp_parser*, bool)
(parser.c:10300)
==30972==    by 0x6A13EB: cp_parser_declaration(cp_parser*) (parser.c:10196)
==30972==    by 0x69FFF7: cp_parser_declaration_seq_opt(cp_parser*)
(parser.c:10082)
==30972==    by 0x6A1962: c_parse_file() (parser.c:3791)
==30972==    by 0x79F814: c_common_parse_file() (c-opts.c:1117)
==30972==    by 0xB8104F: toplev_main(int, char**) (toplev.c:557)
==30972==    by 0x66E009C: (below main) (in /lib64/libc-2.13.so)
==30972==  Address 0x4 is not stack'd, malloc'd or (recently) free'd
==30972== 
/mnt/svn/gcc-trunk/gcc/testsuite/g++.dg/parse/crash54.C:10:8: 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.

Tested revisions:
r183351 - crash

Reply via email to