Stacktraces with dwarf symbols #280

Open
icex2 wants to merge 4 commits from icex2/stacktraces-with-dwarf-syms into development
4 Commits
Author SHA1 Message Date
icex2 121b961301 fix(make): Include dwarf symbols and remove stripping
Expecting to improve debugability significantly. Stacktraces
can be enhanced with function names, file names and line
numbers when symbols are included in all exe and dll files.

Furthermore, this also improves debugger usage as symbols
can be imported to help navigate disassembly/decompiled code.
2024-01-31 21:21:00 +01:00
icex2 c15da8eed1 feat(inject): Use new exception handler with stacktraces
Adjust inject to utilize the new feature. This also
requires including the dwarfstack.dll in all distribution
packages.
2024-01-31 21:21:00 +01:00
icex2 8eefb2d477 feat(util): Separate debug module with proper stacktrace printing
Because we are using mingw, we can't just use window's
dbghelp library as the symbols created are in dwarf format.

Fortunately, the dwarfstack library already provides all the
facilities to easily print very descriptive stacktraces,
including function names, file names and line numbers,
when dwarf symbols are available.

This moves the incomplete exception handling portion from
signal to a separate module as well to improve scoping.
2024-01-31 21:21:00 +01:00
icex2 69e469858c feat(util): Add log function for logging in exception handlers
We want this to always be visible, so the log level must be
the highest possible. Unfortunately, that's quite the hack
around the existing API and how fatal behaves.

The log API stopped scaling already a while ago and needs
considerable refactoring to consider the various use-cases
that emerged since it was first created on alpha versions
of bemanitools.
2024-01-31 21:21:00 +01:00