public inbox for dwz@sourceware.org
 help / color / mirror / Atom feed
* [Bug default/24823] New: [dwz] Bad DW_OP_GNU_variable_value DIE
@ 2019-01-01  0:00 vries at gcc dot gnu.org
  2019-01-01  0:00 ` [Bug default/24823] " vries at gcc dot gnu.org
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: vries at gcc dot gnu.org @ 2019-01-01  0:00 UTC (permalink / raw)
  To: dwz

https://sourceware.org/bugzilla/show_bug.cgi?id=24823

            Bug ID: 24823
           Summary: [dwz] Bad DW_OP_GNU_variable_value DIE
           Product: dwz
           Version: unspecified
            Status: NEW
          Severity: normal
          Priority: P2
         Component: default
          Assignee: nobody at sourceware dot org
          Reporter: vries at gcc dot gnu.org
                CC: dwz at sourceware dot org
  Target Milestone: ---

[ Spinoff of PR24728 - "varval FAILs with cc-with-dwz-m" ]

With the gdb.dwarf2/varval.exp test-case of gdb, we have:
...
$ gdb -q -batch varval -ex start -ex "print constval"
Temporary breakpoint 1 at 0x4004ab

Temporary breakpoint 1, 0x00000000004004ab in main ()
Bad DW_OP_GNU_variable_value DIE.
...

In the original exec we have a DIE with DW_OP_GNU_variable_value ref to DIE
0x112:
...
 <1><112>: Abbrev Number: 8 (DW_TAG_variable)
    <113>   DW_AT_name        : var_c
    <119>   DW_AT_type        : <0xd4>
    <11d>   DW_AT_external    : 1
    <11e>   DW_AT_const_value : 53
 ...
 <2><1f7>: Abbrev Number: 25 (DW_TAG_variable)
    <1f8>   DW_AT_name        : constval
    <201>   DW_AT_type        : <0xd4>
    <205>   DW_AT_location    : 6 byte block: fd 12 1 0 0 9f   
(DW_OP_GNU_variable_value: <0x112>; DW_OP_stack_value)
...
but after dwz -m we have moved var_c to the multifile:
...
 <1><86>: Abbrev Number: 1 (DW_TAG_variable)
    <87>   DW_AT_name        : var_c
    <8d>   DW_AT_type        : <0x7a>
    <8e>   DW_AT_external    : 1
    <8f>   DW_AT_const_value : 53
...
while constval has not, and now has an invalid DW_OP_GNU_variable_value ref:
...
 <2><159>: Abbrev Number: 18 (DW_TAG_variable)
    <15a>   DW_AT_name        : constval
    <163>   DW_AT_type        : <alt 0x7a>
    <167>   DW_AT_location    : 6 byte block: fd 4 0 0 0 9f    
(DW_OP_GNU_variable_value: <0x4>; DW_OP_stack_value)
...

So this is a dwz bug rather than a gdb bug.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2019-07-19 12:13 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-01-01  0:00 [Bug default/24823] New: [dwz] Bad DW_OP_GNU_variable_value DIE vries at gcc dot gnu.org
2019-01-01  0:00 ` [Bug default/24823] " vries at gcc dot gnu.org
2019-01-01  0:00 ` vries at gcc dot gnu.org
2019-01-01  0:00 ` vries at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).