public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/109719] New: Truncated frame-pointer unwinding via Linux perf with g++
@ 2023-05-03 20:21 chergert at redhat dot com
  2023-05-03 20:23 ` [Bug c++/109719] " chergert at redhat dot com
                   ` (8 more replies)
  0 siblings, 9 replies; 10+ messages in thread
From: chergert at redhat dot com @ 2023-05-03 20:21 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 109719
           Summary: Truncated frame-pointer unwinding via Linux perf with
                    g++
           Product: gcc
           Version: 13.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: chergert at redhat dot com
  Target Milestone: ---

On Fedora 38, frame-pointers are enabled by default. Caveats of course.

However, I noticed that clang++ is generating code that can unwind with
frame-pointers just fine where as g++ is generating code that fails to unwind
past a single frame for some projects.

Where I've noticed this is when profiling GTK/GNOME applications. Harfbuzz,
which is C++ (no-rtti, no-exceptions, no-threadsafe-statics, and no stdlibc++),
regularly results in stacktraces from Linux perf containing 2 frames. One of
them looks corrupted, and the second to a Harfbuzz function.

When I recompile the project with clang++ instead (leaving the rest of the
system still compiled with gcc) I get proper stacktraces from Linux perf
showing how the Harfbuzz API was called (via GLib/GTK/Pango/etc).

Happy to provide more information and/or be remote hands/eyes.

Thanks!

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

end of thread, other threads:[~2023-05-03 20:43 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-05-03 20:21 [Bug c++/109719] New: Truncated frame-pointer unwinding via Linux perf with g++ chergert at redhat dot com
2023-05-03 20:23 ` [Bug c++/109719] " chergert at redhat dot com
2023-05-03 20:28 ` [Bug target/109719] " pinskia at gcc dot gnu.org
2023-05-03 20:29 ` pinskia at gcc dot gnu.org
2023-05-03 20:31 ` chergert at redhat dot com
2023-05-03 20:33 ` chergert at redhat dot com
2023-05-03 20:36 ` chergert at redhat dot com
2023-05-03 20:38 ` chergert at redhat dot com
2023-05-03 20:39 ` pinskia at gcc dot gnu.org
2023-05-03 20:43 ` chergert 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).