kcbanner
ad5f74c0b1
dwarf: introduce ExpressionContext, add more expression opcodes
2023-07-20 22:58:14 -04:00
kcbanner
b85f84061a
dwarf: don't dupe function names, as they are backed by the memory mapped sections
...
dwarf: const-correctness fixups
dwarf: implement the remaining register rules
dwarf: start implmenting the DWARF expression stack machine
2023-07-20 22:58:14 -04:00
kcbanner
89ef004646
debug: x86 unwinding support, more unwinding fixes
...
- Fix unwindFrame using the previous FDE row instead of the current one
- Handle unwinding through noreturn functions
- Add x86-linux getcontext
- Fixup x86_64-linux getcontext not restoring the fp env
- Fix start_addr filtering on x86-windows
2023-07-20 22:58:14 -04:00
kcbanner
6abf1fbfe6
update to new builtin syntax
2023-07-20 22:58:14 -04:00
kcbanner
a47212c72e
- rebase and update to lastest master
2023-07-20 22:58:13 -04:00
kcbanner
5781016c35
dwarf: add support for .eh_frame_hdr when unwinding
...
- .eh_frame_hdr contains a binary-searchable data structure for finding an FDE. If present, we can use this
section to avoid having to parse the entire FDE/CIE list in the binary, instead only entries that are actually
required for unwinding are read.
- rework the inputs pc-relative pointer decoding to support both already-mapped sections as well as sections
mapped from a file
- store the VirtualMachine on UnwindContext so the allocations can be reused
2023-07-20 22:58:13 -04:00
kcbanner
551f153718
dwarf: fixes for non-64 bit systems
2023-07-20 22:58:13 -04:00
kcbanner
c98e03fc7e
- rework CFI instruction parsing to not use std.meta
...
- move register formatting code to zig-dwardump
2023-07-20 22:58:13 -04:00
kcbanner
9145ff7da0
dwarf: implement more register number mappings
...
- add dwarf.abi.RegisterContext to handle register numbers changing based on DWARF format
2023-07-20 22:58:13 -04:00
kcbanner
b449d98a93
- rework StackIterator to optionally use debug_info to unwind the stack
...
- add abi routines for getting register values
- unwding is working!
2023-07-20 22:58:13 -04:00
kcbanner
69399fbb82
- add default register rule
...
- fixup eh pointer decoding
2023-07-20 22:58:13 -04:00
kcbanner
a0a40c2e7e
- implement more opcodes
2023-07-20 22:58:13 -04:00
kcbanner
7b4611cfb3
- move writing code to zig-dwarfdump
...
- implement restore_state, restore_extended, offset_extended
2023-07-20 22:58:13 -04:00
kcbanner
338df862d1
- fix remember_state
...
- implement def_cfa_register
2023-07-20 22:58:13 -04:00
kcbanner
f3f3c877e0
- add DWARF expression parser
...
- change read apis to use a stream
- add register formatters
2023-07-20 22:58:13 -04:00
kcbanner
38303d7b9c
add VirtualMachine to run CFA instructions
2023-07-20 22:58:13 -04:00
kcbanner
8b8d627137
- add call frame instruction parser
...
- add register printing
2023-07-20 22:58:13 -04:00