public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug debug/60476] New: DWARF DW_AT_declaration && DW_AT_low_pc
@ 2014-03-09 18:08 jan.kratochvil at redhat dot com
0 siblings, 0 replies; only message in thread
From: jan.kratochvil at redhat dot com @ 2014-03-09 18:08 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60476
Bug ID: 60476
Summary: DWARF DW_AT_declaration && DW_AT_low_pc
Product: gcc
Version: 4.8.2
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: debug
Assignee: unassigned at gcc dot gnu.org
Reporter: jan.kratochvil at redhat dot com
Host: x86_64-unknown-linux-gnu
Target: x86_64-redhat-linux-gnu
Created attachment 32318
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=32318&action=edit
GDB test patch to catch such DWARF.
GCC Ada DWARF IMO violates DWARF-4:
3.3.3 Subroutine and Entry Point Locations
A subroutine entry representing a subroutine declaration that is not also a
definition does not have code address or range attributes.
<2><46935>: Abbrev Number: 116 (DW_TAG_subprogram)
<46936> DW_AT_abstract_origin: <0x45e96>
<4693a> DW_AT_declaration : 1
<2><45e96>: Abbrev Number: 113 (DW_TAG_subprogram)
<45e97> DW_AT_name : atree__copy_separate_tree__copy_list
<45e9b> DW_AT_decl_file : 2
<45e9c> DW_AT_decl_line : 805
<45e9e> DW_AT_type : <0x355a6>
<45ea2> DW_AT_low_pc : 0x44ebf0
<45eaa> DW_AT_high_pc : 0x2a2
<45eb2> DW_AT_frame_base : 1 byte block: 9c (DW_OP_call_frame_cfa)
<45eb4> DW_AT_GNU_all_call_sites: 1
The first DIE <46935> is used only by:
<4><46be8>: Abbrev Number: 103 (DW_TAG_GNU_call_site)
<46be9> DW_AT_low_pc : 0x44f579
<46bf1> DW_AT_abstract_origin: <0x46935>
<46bf5> DW_AT_sibling : <0x46c00>
I have not seen this kind of DIE in non-Ada builds but I cannot prove it.
If not anything else it is a redundant DIE, DW_TAG_GNU_call_site could point to
<45e96> directly.
Steps to Reproduce:
../gcc48/configure --enable-languages=ada --enable-bootstrap
make profiledbootstrap
../fresh-new-gdb/gdb/gdb -readnow gcc/gnatbind
(Formerly filed as in fact unrelated PR debug/60339.)
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2014-03-09 18:08 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-03-09 18:08 [Bug debug/60476] New: DWARF DW_AT_declaration && DW_AT_low_pc jan.kratochvil at redhat dot com
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).