[Bug debug/88046] [9 Regression] ICE in add_data_member_location_attribute at gcc/dwarf2out.c:19237 since r261885

jakub at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Fri Nov 16 11:40:00 GMT 2018


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88046

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |jakub at gcc dot gnu.org

--- Comment #1 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
19236             /* Calculate the address of the offset.  */
19237             offset = tree_to_shwi (BINFO_VPTR_FIELD (decl));
19238             gcc_assert (offset < 0);
#1  0x00000000013c98ad in tree_to_shwi (t=0x0) at ../../gcc/tree.c:7084
#2  0x00000000009e4056 in add_data_member_location_attribute (
    die=<dw_die_ref 0x7fffefa895f0 DW_TAG_inheritance <parent=0x7fffefa895a0
DW_TAG_structure_type>>, decl=<tree_binfo 0x7fffefa81000>, 
    ctx=0x7fffffffce80) at ../../gcc/dwarf2out.c:19237
#3  0x00000000009f3195 in gen_inheritance_die (binfo=<tree_binfo
0x7fffefa81000>, access=<identifier_node 0x7fffefc937f8 public>, 
    type=<record_type 0x7fffefe7a3f0 b>, 
    context_die=<dw_die_ref 0x7fffefa895a0 DW_TAG_structure_type
<parent=0x7fffefa89000 DW_TAG_compile_unit>>) at ../../gcc/dwarf2out.c:24511
#4  0x00000000009f44d1 in gen_member_die (type=<record_type 0x7fffefe7a3f0 b>, 
    context_die=<dw_die_ref 0x7fffefa895a0 DW_TAG_structure_type
<parent=0x7fffefa89000 DW_TAG_compile_unit>>) at ../../gcc/dwarf2out.c:24982
#5  0x00000000009f4eb9 in gen_struct_or_union_type_die (type=<record_type
0x7fffefe7a3f0 b>, 
    context_die=<dw_die_ref 0x7fffefa89500 DW_TAG_lexical_block
<parent=0x7fffefa89460 DW_TAG_subprogram>>, usage=DINFO_USAGE_DIR_USE)
    at ../../gcc/dwarf2out.c:25155
#6  0x00000000009f599a in gen_tagged_type_die (type=<record_type 0x7fffefe7a3f0
b>, 
    context_die=<dw_die_ref 0x7fffefa89500 DW_TAG_lexical_block
<parent=0x7fffefa89460 DW_TAG_subprogram>>, usage=DINFO_USAGE_DIR_USE)
    at ../../gcc/dwarf2out.c:25356
#7  0x00000000009f62f1 in gen_type_die_with_usage (type=<record_type
0x7fffefe7a3f0 b>, 
    context_die=<dw_die_ref 0x7fffefa89500 DW_TAG_lexical_block
<parent=0x7fffefa89460 DW_TAG_subprogram>>, usage=DINFO_USAGE_DIR_USE)
    at ../../gcc/dwarf2out.c:25551
#8  0x00000000009f668e in gen_type_die (type=<record_type 0x7fffefe7a3f0 b>, 
    context_die=<dw_die_ref 0x7fffefa89500 DW_TAG_lexical_block
<parent=0x7fffefa89460 DW_TAG_subprogram>>) at ../../gcc/dwarf2out.c:25605
#9  0x00000000009d1c3e in modified_type_die (type=<record_type 0x7fffefe7a3f0
b>, cv_quals=0, reverse=false, 
    context_die=<dw_die_ref 0x7fffefa89500 DW_TAG_lexical_block
<parent=0x7fffefa89460 DW_TAG_subprogram>>) at ../../gcc/dwarf2out.c:13368
#10 0x00000000009ea658 in add_type_attribute (
    object_die=<dw_die_ref 0x7fffefa89550 DW_TAG_variable
<parent=0x7fffefa89500 DW_TAG_lexical_block>>, type=<record_type 0x7fffefe7a3f0
b>, 
    cv_quals=0, reverse=false, context_die=<dw_die_ref 0x7fffefa89500
DW_TAG_lexical_block <parent=0x7fffefa89460 DW_TAG_subprogram>>)
    at ../../gcc/dwarf2out.c:21532
#11 0x00000000009f0985 in gen_variable_die (decl=<var_decl 0x7ffff7ff6f30 d>,
origin=<tree 0x0>, 
    context_die=<dw_die_ref 0x7fffefa89500 DW_TAG_lexical_block
<parent=0x7fffefa89460 DW_TAG_subprogram>>) at ../../gcc/dwarf2out.c:23774
#12 0x00000000009f880d in gen_decl_die (decl=<var_decl 0x7ffff7ff6f30 d>,
origin=<tree 0x0>, ctx=0x0, 
    context_die=<dw_die_ref 0x7fffefa89500 DW_TAG_lexical_block
<parent=0x7fffefa89460 DW_TAG_subprogram>>) at ../../gcc/dwarf2out.c:26297
#13 0x00000000009f6d86 in process_scope_var (stmt=<block 0x7fffefa81300>,
decl=<var_decl 0x7ffff7ff6f30 d>, origin=<tree 0x0>, 
    context_die=<dw_die_ref 0x7fffefa89500 DW_TAG_lexical_block
<parent=0x7fffefa89460 DW_TAG_subprogram>>) at ../../gcc/dwarf2out.c:25758
#14 0x00000000009f6e0f in decls_for_scope (stmt=<block 0x7fffefa81300>, 
    context_die=<dw_die_ref 0x7fffefa89500 DW_TAG_lexical_block
<parent=0x7fffefa89460 DW_TAG_subprogram>>, recurse=true)
    at ../../gcc/dwarf2out.c:25784
#15 0x00000000009f1d75 in gen_lexical_block_die (stmt=<block 0x7fffefa81300>, 
    context_die=<dw_die_ref 0x7fffefa89460 DW_TAG_subprogram
<parent=0x7fffefa89000 DW_TAG_compile_unit>>) at ../../gcc/dwarf2out.c:24111
#16 0x00000000009f6944 in gen_block_die (stmt=<block 0x7fffefa81300>, 
    context_die=<dw_die_ref 0x7fffefa89460 DW_TAG_subprogram
<parent=0x7fffefa89000 DW_TAG_compile_unit>>) at ../../gcc/dwarf2out.c:25690
#17 0x00000000009f6f8c in decls_for_scope (stmt=<block 0x7fffefa81240>, 
    context_die=<dw_die_ref 0x7fffefa89460 DW_TAG_subprogram
<parent=0x7fffefa89000 DW_TAG_compile_unit>>, recurse=true)
    at ../../gcc/dwarf2out.c:25813
#18 0x00000000009ef14e in gen_subprogram_die (decl=<function_decl
0x7fffefe7be00 c>, context_die=<dw_die_ref 0x7fffefa89000 DW_TAG_compile_unit>)
    at ../../gcc/dwarf2out.c:23259
#19 0x00000000009f841e in gen_decl_die (decl=<function_decl 0x7fffefe7be00 c>,
origin=<tree 0x0>, ctx=0x0, 
    context_die=<dw_die_ref 0x7fffefa89000 DW_TAG_compile_unit>) at
../../gcc/dwarf2out.c:26214
#20 0x00000000009f9b35 in dwarf2out_decl (decl=<function_decl 0x7fffefe7be00
c>) at ../../gcc/dwarf2out.c:26782
#21 0x00000000009f9b91 in dwarf2out_function_decl (decl=<function_decl
0x7fffefe7be00 c>) at ../../gcc/dwarf2out.c:26797
#22 0x0000000000ab7ea0 in rest_of_handle_final () at ../../gcc/final.c:4681

Bet the type is pruned and then re-added later or something similar.


More information about the Gcc-bugs mailing list