public inbox for gdb@sourceware.org
 help / color / mirror / Atom feed
* [Fwd: Initial register state of unspecified CIE.INITIAL_INSTRUCTIONS?]
@ 2003-08-13 17:30 Andrew Cagney
  0 siblings, 0 replies; only message in thread
From: Andrew Cagney @ 2003-08-13 17:30 UTC (permalink / raw)
  To: gdb

[-- Attachment #1: Type: text/plain, Size: 13 bytes --]

FYI,

Andrew

[-- Attachment #2: Initial register state of unspecified CIE.INITIAL_INSTRUCTIONS? --]
[-- Type: message/rfc822, Size: 3862 bytes --]

From: Andrew Cagney <ac131313@redhat.com>
To: Dwarf 2 List <dwarf2@els.sgi.com>
Subject: Initial register state of unspecified CIE.INITIAL_INSTRUCTIONS?
Date: Wed, 13 Aug 2003 00:10:17 -0400
Message-ID: <3F39BA29.4050003@redhat.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



^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2003-08-13 17:30 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-08-13 17:30 [Fwd: Initial register state of unspecified CIE.INITIAL_INSTRUCTIONS?] Andrew Cagney

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).