<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0"><channel><title>mikeash.com pyblog/friday-qa-2012-04-27-plcrashreporter-and-unwinding-the-stack-with-dwarf.html comments</title><link>http://www.mikeash.com/?page=pyblog/friday-qa-2012-04-27-plcrashreporter-and-unwinding-the-stack-with-dwarf.html#comments</link><description>mikeash.com Recent Comments</description><lastBuildDate>Sun, 10 May 2026 05:43:02 GMT</lastBuildDate><generator>PyRSS2Gen-1.0.0</generator><docs>http://blogs.law.harvard.edu/tech/rss</docs><item><title>Mark Aufflick - 2012-05-01 03:55:58</title><link>http://www.mikeash.com/?page=pyblog/friday-qa-2012-04-27-plcrashreporter-and-unwinding-the-stack-with-dwarf.html#comments</link><description>Wow this is exciting. None of my Mac apps ship via the app store not yet, but not having crash reporting has made me dread the app store. Not for much longer though - good work Gwynne and the always awesome HockeyApp guys!</description><guid isPermaLink="true">8272ca22175e793d9b51c3b03325c824</guid><pubDate>Tue, 01 May 2012 03:55:58 GMT</pubDate></item><item><title>Landon Fuller - 2012-04-27 19:57:43</title><link>http://www.mikeash.com/?page=pyblog/friday-qa-2012-04-27-plcrashreporter-and-unwinding-the-stack-with-dwarf.html#comments</link><description>Unfortunately upstream libunwind doesn't support Darwin, Mach-O, or the compact unwind encoding.
&lt;br /&gt;
&lt;br /&gt;Apple has their own open-source implementation of a small subset of libunwind, but it's licensed under the APSL, and the version shipped with Mac OS X can't be used for our purposes without relying on private API and/or undefined semantics. Given the redistribution requirements around the APSL that could affect library users themselves, shipping our own customized version of Apple's minimal libunwind wasn't deemed workable.
&lt;br /&gt;
&lt;br /&gt;Gwynne's work ultimately provides a standalone async-safe, C-based, MIT-licensed frame walking implementation.</description><guid isPermaLink="true">263e4767722a5b44b021b2a9d4284d86</guid><pubDate>Fri, 27 Apr 2012 19:57:43 GMT</pubDate></item><item><title>Joe Groff - 2012-04-27 19:06:29</title><link>http://www.mikeash.com/?page=pyblog/friday-qa-2012-04-27-plcrashreporter-and-unwinding-the-stack-with-dwarf.html#comments</link><description>Good points, Landon. How about libunwind then? &lt;a href="http://www.nongnu.org/libunwind/"&gt;http://www.nongnu.org/libunwind/&lt;/a&gt;</description><guid isPermaLink="true">fff77e493954a3dc23d2e26c14623865</guid><pubDate>Fri, 27 Apr 2012 19:06:29 GMT</pubDate></item><item><title>Landon Fuller - 2012-04-27 16:15:39</title><link>http://www.mikeash.com/?page=pyblog/friday-qa-2012-04-27-plcrashreporter-and-unwinding-the-stack-with-dwarf.html#comments</link><description>Hey Joe --
&lt;br /&gt;
&lt;br /&gt;Unfortunately neither of those are async-safe, can only be used on the current thread, and can hide information that is necessary in a crash reporter. I've written a bit more about the issues involved in crash reporting here:
&lt;br /&gt;
&lt;br /&gt;&lt;a href="http://landonf.bikemonkey.org/code/objc/Reliable_Crash_Reporting.20110912.html"&gt;http://landonf.bikemonkey.org/code/objc/Reliable_Crash_Reporting.20110912.html&lt;/a&gt;</description><guid isPermaLink="true">fdbda5c522a9e36a471770b17281a1a8</guid><pubDate>Fri, 27 Apr 2012 16:15:39 GMT</pubDate></item><item><title>Landon Fuller - 2012-04-27 16:13:30</title><link>http://www.mikeash.com/?page=pyblog/friday-qa-2012-04-27-plcrashreporter-and-unwinding-the-stack-with-dwarf.html#comments</link><description>Hi Chris --
&lt;br /&gt;
&lt;br /&gt;There can be a measurable performance gain when making the extra register available, assuming that the compiler's heuristics for doing so aren't broken, and you're spending more time executing code that benefits from the register than you spend stack walking (usually a safe bet?).
&lt;br /&gt;
&lt;br /&gt;If I recall correctly, certain GCC versions would *prefer* the callee-saved frame pointer over other callee-stompable registers when -fomit-frame-pointer was specified on x86. This lead to *less* efficient code, since it would have been more efficient to use a register that didn't require callee-preservation.
&lt;br /&gt;
&lt;br /&gt;On x86-64, the ABI explicitly specifies that -fomit-frame-pointer semantics are the default, so it couldn't be relied on for crash reporting even if we wanted to.</description><guid isPermaLink="true">3d6a72514a0a80d0555b21be09df0352</guid><pubDate>Fri, 27 Apr 2012 16:13:30 GMT</pubDate></item><item><title>Joe Groff - 2012-04-27 16:11:58</title><link>http://www.mikeash.com/?page=pyblog/friday-qa-2012-04-27-plcrashreporter-and-unwinding-the-stack-with-dwarf.html#comments</link><description>You can use the libc functions backtrack, backtrace_symbols, and backtrace_symbols_fd to get this same information.</description><guid isPermaLink="true">16f78712cc6c48d6c279c01d88172ff8</guid><pubDate>Fri, 27 Apr 2012 16:11:58 GMT</pubDate></item><item><title>Farcaller - 2012-04-27 14:43:45</title><link>http://www.mikeash.com/?page=pyblog/friday-qa-2012-04-27-plcrashreporter-and-unwinding-the-stack-with-dwarf.html#comments</link><description>It would be nice to see the same in corellation to arm binaries.</description><guid isPermaLink="true">d993957aa4db950656f125191488d29f</guid><pubDate>Fri, 27 Apr 2012 14:43:45 GMT</pubDate></item><item><title>Chris - 2012-04-27 14:40:37</title><link>http://www.mikeash.com/?page=pyblog/friday-qa-2012-04-27-plcrashreporter-and-unwinding-the-stack-with-dwarf.html#comments</link><description>Wouldn't building with stack frame pointers be a lot easier? Is there a measurable performance reason why they're omitted in release builds?</description><guid isPermaLink="true">493b9e9d299da06b75d912759981381b</guid><pubDate>Fri, 27 Apr 2012 14:40:37 GMT</pubDate></item></channel></rss>
