Page MenuHomePhabricator

[RFC] Support DWARF expressions in CFI instructions
Needs ReviewPublic

Authored by rafauler on Mar 9 2021, 3:43 PM.



This adds minimal support in MCStreamer to encode DWARF expressions when
emitting CFI. This is used by BOLT when reading binaries that contain
such constructs and we need to be able to write them back to the final
binary so we preserve correct unwinding info.

I wanted to post this as an RFC because I noticed that other MCStreamer
users are emitting DWARF expressions using cfi_escape. Is there interest
to support emission in MCStreamer, or should we move this logic to BOLT
and use cfi_escape too? Thanks!

Diff Detail