public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug lto/43377]  New: lto decreases stacktrace readability (debuginfo pubnames).
@ 2010-03-15 11:48 pluto at agmk dot net
  2010-03-15 11:50 ` [Bug lto/43377] " pluto at agmk dot net
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: pluto at agmk dot net @ 2010-03-15 11:48 UTC (permalink / raw)
  To: gcc-bugs

$ make clean all
rm -f *.o *.s *.ii m
g++45 -Wall -g2 -O1  a.cpp -c
g++45 -Wall -g2 -O1  m.cpp -c
g++45 -Wall -g2 -O1  a.o m.o -o m --save-temps -fverbose-asm

$ readelf --debug-dump=pubnames ./m
(...)

    Offset      Name
    8e7         Y::foo                 <==
    913         X::foo                 <==
    968         X::~X
    98f         Y::~Y
    9b6         Y::~Y
    9fe         X::~X
    a3a         X::X
    a61         X::bar

(gdb) break Y::foo()
Breakpoint 1 at 0x400768: file a.cpp, line 25.

(gdb) bt
#0  Y::foo (this=0x7fffffffe1c0) at a.cpp:26
    ^^^^^^ readable location with namespace/class prefix.


now the same with -flto.

$ make clean all LTOFLAGS=-flto
rm -f *.o *.s *.ii m
g++45 -Wall -g2 -O1 -flto a.cpp -c
g++45 -Wall -g2 -O1 -flto m.cpp -c
g++45 -Wall -g2 -O1 -flto a.o m.o -o m --save-temps -fverbose-asm

    Offset      Name
    87          foo                  <==
    ca          foo                  <==
    10d         __base_dtor
    12c         __base_dtor
    14b         __deleting_dtor
    183         __deleting_dtor
    1a2         __base_ctor
    1c1         bar
    1f5         main

(gdb) b Y::foo()
Breakpoint 1 at 0x400768: file a.cpp, line 24.

(gdb) bt
#0  foo (this=0x7fffffffe1c0) at a.cpp:26
    ^^^ some cryptic foo.


-- 
           Summary: lto decreases stacktrace readability (debuginfo
                    pubnames).
           Product: gcc
           Version: 4.5.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: lto
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: pluto at agmk dot net
 GCC build triplet: x86_64-gnu-linux
  GCC host triplet: x86_64-gnu-linux
GCC target triplet: x86_64-gnu-linux


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


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

* [Bug lto/43377] lto decreases stacktrace readability (debuginfo pubnames).
  2010-03-15 11:48 [Bug lto/43377] New: lto decreases stacktrace readability (debuginfo pubnames) pluto at agmk dot net
@ 2010-03-15 11:50 ` pluto at agmk dot net
  2010-03-15 12:51 ` [Bug lto/43377] lto decreases C++ " rguenth at gcc dot gnu dot org
  2010-04-23 13:23 ` rguenth at gcc dot gnu dot org
  2 siblings, 0 replies; 5+ messages in thread
From: pluto at agmk dot net @ 2010-03-15 11:50 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from pluto at agmk dot net  2010-03-15 11:50 -------
Created an attachment (id=20108)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=20108&action=view)
testcase


-- 


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


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

* [Bug lto/43377] lto decreases C++ stacktrace readability (debuginfo pubnames).
  2010-03-15 11:48 [Bug lto/43377] New: lto decreases stacktrace readability (debuginfo pubnames) pluto at agmk dot net
  2010-03-15 11:50 ` [Bug lto/43377] " pluto at agmk dot net
@ 2010-03-15 12:51 ` rguenth at gcc dot gnu dot org
  2010-04-23 13:23 ` rguenth at gcc dot gnu dot org
  2 siblings, 0 replies; 5+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2010-03-15 12:51 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from rguenth at gcc dot gnu dot org  2010-03-15 12:51 -------
Because we drop DECL_CONTEXT.


-- 

rguenth at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|0                           |1
           Keywords|                            |lto
   Last reconfirmed|0000-00-00 00:00:00         |2010-03-15 12:51:07
               date|                            |
            Summary|lto decreases stacktrace    |lto decreases C++ stacktrace
                   |readability (debuginfo      |readability (debuginfo
                   |pubnames).                  |pubnames).


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


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

* [Bug lto/43377] lto decreases C++ stacktrace readability (debuginfo pubnames).
  2010-03-15 11:48 [Bug lto/43377] New: lto decreases stacktrace readability (debuginfo pubnames) pluto at agmk dot net
  2010-03-15 11:50 ` [Bug lto/43377] " pluto at agmk dot net
  2010-03-15 12:51 ` [Bug lto/43377] lto decreases C++ " rguenth at gcc dot gnu dot org
@ 2010-04-23 13:23 ` rguenth at gcc dot gnu dot org
  2 siblings, 0 replies; 5+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2010-04-23 13:23 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #3 from rguenth at gcc dot gnu dot org  2010-04-23 13:23 -------
(In reply to comment #2)
> Because we drop DECL_CONTEXT.

Rather because lang_hooks.dwarf_name returns what
lang_hooks.decl_printable_name
returns which in turn returns DECL_NAME.

We can either save what the langhook produces in DECL_NAME during fld or
for example use the assembler name (which is mangled).  Of course the
langhook has a variant to request a name with or without the scope ...


-- 


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


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

* [Bug lto/43377] lto decreases C++ stacktrace readability (debuginfo pubnames).
       [not found] <bug-43377-4@http.gcc.gnu.org/bugzilla/>
@ 2012-03-15 21:23 ` pluto at agmk dot net
  0 siblings, 0 replies; 5+ messages in thread
From: pluto at agmk dot net @ 2012-03-15 21:23 UTC (permalink / raw)
  To: gcc-bugs

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

Pawel Sikora <pluto at agmk dot net> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED

--- Comment #4 from Pawel Sikora <pluto at agmk dot net> 2012-03-15 20:21:13 UTC ---
seems to be fixed on 4.6+


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

end of thread, other threads:[~2012-03-15 20:21 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-03-15 11:48 [Bug lto/43377] New: lto decreases stacktrace readability (debuginfo pubnames) pluto at agmk dot net
2010-03-15 11:50 ` [Bug lto/43377] " pluto at agmk dot net
2010-03-15 12:51 ` [Bug lto/43377] lto decreases C++ " rguenth at gcc dot gnu dot org
2010-04-23 13:23 ` rguenth at gcc dot gnu dot org
     [not found] <bug-43377-4@http.gcc.gnu.org/bugzilla/>
2012-03-15 21:23 ` pluto at agmk dot net

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).