--- Begin Message ---
- From: Andrew Cagney <ac131313 at redhat dot com>
- To: Dwarf 2 List <dwarf2 at els dot sgi dot com>
- Date: Wed, 13 Aug 2003 00:10:17 -0400
- Subject: Initial register state of unspecified CIE.INITIAL_INSTRUCTIONS?
- Reply-to: Andrew Cagney <ac131313 at redhat dot com>
Hello,
The CFI is broken down into two parts - a CIE and an FDE. The CIE,
which is shared by multiple FDEs provides the initial settings for all
the registers (in INITIAL_INSTRUCTIONS).
What happens if a compiler fails to provide that information, or if that
information is [very] incomplete? What is the initial state of any
undefined registers? Undefined, ABI committee defined, compiler
dependant, ...
The example in D.5:
cie 32 length
cie+4 0xffffffff CIE_id
cie+8 1 version
cie+9 0 augmentation
cie+10 4 code_alignment_factor, <c
cie+11 -4 data_alignment_factor, <d
cie+12 8 R8 is the return addr.
cie+13 DW_CFA_def_cfa (7, 0) CFA = [R7]+0
cie+16 DW_CFA_same_value (0) R0 not modified (=0)
cie+18 DW_CFA_undefined (1) R1 scratch
cie+20 DW_CFA_undefined (2) R2 scratch
cie+22 DW_CFA_undefined (3) R3 scratch
cie+24 DW_CFA_same_value (4) R4 preserve
cie+26 DW_CFA_same_value (5) R5 preserve
cie+28 DW_CFA_same_value (6) R6 preserve
cie+30 DW_CFA_same_value (7) R7 preserve
cie+32 DW_CFA_register (8, 1) R8 is in R1
cie+35 DW_CFA_nop padding
cie+36
strongly suggests that the intent was for the compiler to provide a
completly populated initial table row, however I'm struggling to find
any definitive language in the spec proper supporting this.
Andrew
--- End Message ---