News for hackers. Stuff that matters.
Re:How to build highly-debuggable C++ binaries by saagarjha on Monday July 29, 2024 @12:39PM (#41101718)
Is calling dladdr on the addresses not enough for you?
Re:How to build highly-debuggable C++ binaries by jeffbee on Monday July 29, 2024 @12:46PM (#41101769)
It's not async signal safe, so I did not even try that.

I think there's a huge amount of complexity both inherent to the problem and caused by fifty years of accumulated bad habits, which is indicated by the thousands of lines of code in compiler-rt dedicated to handling this issue. I'd like to call their library functions but they are all in private-looking namespaces. I also tried to use the Abseil failure signal handler but it often fails to unwind and even when it does unwind has a habit of just printing unknown for the symbol name or file, and never prints the DSO base addresses.