debug-information

How to build kernel debug info as separate file?

浪子不回头ぞ 提交于 2020-05-28 07:48:50
问题 When we share custom built kernel, It is common to give without debug info. Similar to sudo apt-get install linux-image-$(uname -r)-dbgsym , I would like to create separate debug info file for custom built kernel. Here and here they explained generally. I request to share knowledge on creating separate debug info file for entire linux kernel. For sample program $ gcc -g calc.c $ ls -l total 16 -rwxrwxr-x 1 jeyaram jeyaram 8424 Apr 8 09:44 a.out -rw-rw-r-- 1 jeyaram jeyaram 246 Apr 8 09:32

Does compiling with -g, in itself, degrade performance? [duplicate]

和自甴很熟 提交于 2020-01-01 04:10:50
问题 This question already has answers here : How do debug symbols affect performance of a Linux executable compiled by GCC? (2 answers) Closed 3 years ago . (This is a question about gcc and clang, but might apply to other compilers.) If I compile my C or C++ code, and generate debug info using the -g switch, does this in itself degrade performance of the compiled program in any way... (1.) With minimum optimization ( -O0 )? (2.) With maximum optimization ( -O3 )? Note: I don't mean the

objdump/readelf get variables information

99封情书 提交于 2019-12-25 05:07:13
问题 I need to get the information about global variables from a compiled c program. I asked a similar question in here. The problem that I have now is that the program where I am trying to extract the variables info is very big and it takes 4 seconds just to get the tree in text ( readelf -w[i] file.out ). Then I have to parse the tree jumping back and forth in order to get to the place that I need. For example if a variable is of type const unsigned char * volatile MyVariable then I will have to

Any Java counterpart for `/usr/bin/strip`?

笑着哭i 提交于 2019-12-23 12:07:00
问题 Is there any tool that can remove debug info from Java .class files, just like /usr/bin/strip can from C/C++ object files on Linux? EDIT: I liked both Thilo's and Peter Mmm's answers: Peter's was short and to the point exposing my ignorance of what ships with JDK; Thilo's ProGuard suggestion is something I'll definitely be checking out anyway for all those extra features it appears to provide. Thank you Thilo and Peter! 回答1: ProGuard (which the Android SDK for example ships with to reduce

What is Debug Info?

和自甴很熟 提交于 2019-12-11 20:07:53
问题 I am an intermediate C programmer who is learning his way around. I recently learned using GDB (forced to actually) and also am doing some code using Ptrace. I was browsing through some code on ptrace and came across "DEBUG INFO". I want to know what this means and when should I include this in my code? What are debug info files? I couldnt find much from google and wiki related to this. There is no wiki for that tag too. May be if you can point me to the right direction I can repay by writing

Displaying exception debug information to users

社会主义新天地 提交于 2019-11-28 18:29:48
I'm currently working on adding exceptions and exception handling to my OSS application. Exceptions have been the general idea from the start, but I wanted to find a good exception framework and in all honesty, understand C++ exception handling conventions and idioms a bit better before starting to use them. I have a lot of experience with C#/.Net, Python and other languages that use exceptions. I'm no stranger to the idea (but far from a master). In C# and Python, when an unhandled exception occurs, the user gets a nice stack trace and in general a lot of very useful priceless debugging

Displaying exception debug information to users

若如初见. 提交于 2019-11-27 20:20:40
问题 I'm currently working on adding exceptions and exception handling to my OSS application. Exceptions have been the general idea from the start, but I wanted to find a good exception framework and in all honesty, understand C++ exception handling conventions and idioms a bit better before starting to use them. I have a lot of experience with C#/.Net, Python and other languages that use exceptions. I'm no stranger to the idea (but far from a master). In C# and Python, when an unhandled exception