[Dwarf-Discuss] .cfi_offset questions
jonas at lophus.org
Sat Mar 19 04:46:37 PDT 2016
I hope this is the right mailing list to ask this kind of question.
I’m working on a edu/research compiler that has yet to be equipped with DWARF info. Unlike GCC/Clang/… it doesn’t have spill slots that are “constant” within a procedure, i.e. may procedure code like this:
movl %edi, -8(%rbp) # EDI spill slot: -8
movl %eax, -8(%rbp)
movl %edi, -16(%rbp) # EDI spill slot: -16
Is this supported by the DWARF .cfi_offset directives at all, and if so, how? Generally speaking, what’s the “scope”/“validity period”/“life span” of such directive?
As an example, if C were to raise an exception and we’d use stack unwinding, how could the unwinder find the old/callee-saved EDI value?
More information about the Dwarf-Discuss