gimli icon indicating copy to clipboard operation
gimli copied to clipboard

Implement support for CFI unwinding information

Open fitzgen opened this issue 9 years ago • 4 comments
trafficstars

Section 6.4 of the DWARF 4 standard.


TODO:

  • [ ] https://github.com/gimli-rs/gimli/issues/112: Be robust against overflow / casting outside of target type's range
  • [x] https://github.com/gimli-rs/gimli/issues/113: Support .eh_frame augmentation
  • [x] https://github.com/gimli-rs/gimli/issues/114: Benches
  • [x] https://github.com/gimli-rs/gimli/issues/115: Self-parse integration test (requires the .eh_frame augmentation)
  • [ ] https://github.com/gimli-rs/gimli/issues/116: Output this info in dwarfdump.rs
  • [x] https://github.com/gimli-rs/gimli/issues/117: A single, orchestrating DebugFrame::unwind_info_for_address(&self, ctx: &mut UninitializedUnwindContext, address: u64) -> UnwindTableRow method (for folks who don't have any kind of CIE/FDE caching or anything like that)

fitzgen avatar Jul 19 '16 14:07 fitzgen

Going to work on this, now that it seems like @tromey is pretty close to having expressions landable.

fitzgen avatar Aug 28 '16 07:08 fitzgen

Also, http://refspecs.linuxfoundation.org/LSB_4.1.0/LSB-Core-generic/LSB-Core-generic/ehframechpt.html (I think that is the most up to date version of the .eh_frame spec)

Is it worth supporting .debug_frame in addition to .eh_frame? It seems like everything uses the latter these days, AFAICT...

@tromey perhaps you might know?

fitzgen avatar Aug 28 '16 07:08 fitzgen

Is it worth supporting .debug_frame in addition to .eh_frame? It seems like everything uses the latter these days, AFAICT...

I think we want both. Can't rely on either one always existing.

Probably want to also support .ARM.exidx and .ARM.extab for arm/android... Although maybe that should be a different crate?

fitzgen avatar Aug 29 '16 19:08 fitzgen

Probably want to also support .ARM.exidx and .ARM.extab for arm/android... Although maybe that should be a different crate?

http://infocenter.arm.com/help/topic/com.arm.doc.ihi0038b/IHI0038B_ehabi.pdf

fitzgen avatar Sep 20 '16 01:09 fitzgen