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

            Bug ID: 67163
           Summary: g2 generates incorrect decl_line
           Product: gcc
           Version: 6.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: debug
          Assignee: unassigned at gcc dot gnu.org
          Reporter: dehao at gcc dot gnu.org
  Target Milestone: ---

#g++ -c -o ValueStore.o   -O2 -g1        ValueStore.ii
#objdump --dwarf=info ValueStore.o|grep -A 2 isDuplicateOf
    <615>   DW_AT_name        : (indirect string, offset: 0x490): isDuplicateOf
    <619>   DW_AT_decl_file   : 11
    <61a>   DW_AT_decl_line   : 297

#g++ -c -o ValueStore.o   -O2 -g2        ValueStore.ii
#objdump --dwarf=info ValueStore.o|grep -A 2 isDuplicateOf
    <5114>   DW_AT_name        : (indirect string, offset: 0x563d):
isDuplicateOf
    <5118>   DW_AT_decl_file   : 51
    <5119>   DW_AT_decl_line   : 150

g1 generates correct decl_line, but g2 generates incorrect decl_line (150 is
the decl_line for another function: addValue)

Reply via email to