TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Debug Information Is Huge and What to Do About It

76 点作者 sbahra超过 7 年前

6 条评论

dgwynne超过 7 年前
Solaris developed another solution, specifically CTF (Compressed Type Format). CTF stores data types and function signatures rather than full debug info, and is therefore much smaller than the DWARF information it is derived from.<p>The entire Solaris system is built with CTF enabled, which is used to support their debuggers and dtrace. Other systems have adopted it too. OpenBSD is moving to use CTF, and has enabled it&#x27;s use in the kernels and debuggers on some architecture.<p>To get a sense of the size difference, DWARF information for a sparc64 kernel is about 27 megabytes. The CTF information derived from it is 473 kilobytes.
评论 #15590853 未加载
awalton超过 7 年前
Use build-id (<a href="https:&#x2F;&#x2F;fedoraproject.org&#x2F;wiki&#x2F;Releases&#x2F;FeatureBuildId" rel="nofollow">https:&#x2F;&#x2F;fedoraproject.org&#x2F;wiki&#x2F;Releases&#x2F;FeatureBuildId</a>), strip the debug info into its own object file, and point gdb at your debug objects when it comes time to debug.<p>Lean distributable binaries, yet still debugable. Win-win.
评论 #15608227 未加载
bananaboy超过 7 年前
It&#x27;s frustrating when developers distribute binaries without debug information under the mistaken assumption that it&#x27;s going to impact on performance. At a previous company I worked at we were using Scaleform (UI solution for games) and they refused to ship debug information with their release builds. I reported it as a bug and sent them links and information about how it wouldn&#x27;t affect performance, but they still refused. In the end I just built it myself.
评论 #15591549 未加载
loeg超过 7 年前
Minor typo:<p>&gt; A more efficient representation of .debug_rnglists introduced in DWARF 5.<p>Should probably read:<p>&gt; A more efficient representation of .debug_ranges introduced in DWARF 5.<p>Edit: Tangentially, I loved <a href="https:&#x2F;&#x2F;backtrace.io&#x2F;blog&#x2F;compile-once-debug-twice-picking-a-compiler-for-debuggability-1of3&#x2F;" rel="nofollow">https:&#x2F;&#x2F;backtrace.io&#x2F;blog&#x2F;compile-once-debug-twice-picking-a...</a> and am still looking forward to parts 2 and 3. Thanks!
评论 #15590380 未加载
jquast超过 7 年前
Please Arch Linux developers: stop stripping all packages of debug symbols
评论 #15590427 未加载
评论 #15589834 未加载
mabynogy超过 7 年前
The main pain point for me in that domain currently is the wrong results that backtrace() gives when optimizations are enabled.<p>I noticed that clang seems to be better at generating correct infos in such modes.<p>Otherwise I use GDB in &quot;batch mode&quot; to get a callstack triggered by raise(SIGTRAP):<p>&gt; gdb -quiet --batch -ex run -ex backtrace --args $binary $@
评论 #15595645 未加载