You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If you try to get call stacks in perf under Linux for rustc compiled binaries, they are missing unless you compile with debugging. Using Instruments.app on Mac has the symbols though, even without debugging.
The easiest way to reproduce this is to run some Rust release-compiled program under perf record -g and then hit E key in perf report to show call stacks. In debug compiled builds, the call stack symbols are present. In release builds they are meaningless addresses.
Triage: it's been a long time. @metajack you said this was a serious problem for servo, is it still happening, or did you do @michaelwoerister 's workaround?
I'm somewhat confused. Do we somehow include debuginfo in release builds without trying to on macOS? Or does Instruments.app have some form of integrated debuginfo generation?
I've used perf quite a bit lately and have had no problems. However, I don't expect it to work without -C debuginfo=1. Does perf handle C programs (compiled without debuginfo) better?
Activity
pcwalton commentedon Mar 18, 2015
Apparently this works for rustc.
This is a serious problem for Servo.
michaelwoerister commentedon Mar 20, 2015
Can you describe in more detail what exactly you are doing and what the desired outcome should be?
metajack commentedon Mar 20, 2015
The easiest way to reproduce this is to run some Rust release-compiled program under
perf record -gand then hitEkey inperf reportto show call stacks. In debug compiled builds, the call stack symbols are present. In release builds they are meaningless addresses.michaelwoerister commentedon May 9, 2015
You could try building with
-C debuginfo=1. That should give you enough debuginfo for call stacks but not interfere too much with optimization.steveklabnik commentedon Nov 29, 2016
Triage: it's been a long time. @metajack you said this was a serious problem for servo, is it still happening, or did you do @michaelwoerister 's workaround?
metajack commentedon Nov 29, 2016
I think we've just lived with it. @pcwalton does most of his optimization work on macOS. @jdm do you know if this is still happening?
jdm commentedon Nov 29, 2016
This is still necessary on Linux.
jdm commentedon Nov 29, 2016
I don't believe we've ever tried the
-C debuginfo=1workaround, however.Mark-Simulacrum commentedon May 16, 2017
I'm somewhat confused. Do we somehow include debuginfo in release builds without trying to on macOS? Or does Instruments.app have some form of integrated debuginfo generation?
michaelwoerister commentedon May 17, 2017
I've used perf quite a bit lately and have had no problems. However, I don't expect it to work without
-C debuginfo=1. Doesperfhandle C programs (compiled without debuginfo) better?Mark-Simulacrum commentedon Aug 31, 2019
Seems to work without -Cdebuginfo=1 today in perf, at least as far as I can tell.
Merge pull request rust-lang#23488 from hashcatHitman/ref-version-mis…