This is the mail archive of the gdb@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Prologue analysis interface


Jim Blandy wrote:
> On 11/23/05, Ulrich Weigand <uweigand@de.ibm.com> wrote:
> > Just one comment on this:  the CFA is not necessarily the original SP
> > (on s390 we have a constant offset).  We'd have to leave it to platform
> > code to actually determine the CFA itself.
> 
> Why does your CFA need to be an offset from the original SP?  Aside
> from some more code needing to add an offset itself, what would break?

Well, as CFA is just convention, it does *need* an offset as such.
However, fact is that this is how CFA is currently registered in
DWARF-2 CFI generated by GCC (due to an historical accident ...).

Changing this is difficult: if you were to mix object files built with
different CFA base locations, ordering of CFA values along the stack
frame chain would no longer be guaranteed.  (The same would hold if
GDB internally used different CFA conventions for DWARF-2 detected
frames and prolog-parser detected frames ...)

Bye,
Ulrich

-- 
  Dr. Ulrich Weigand
  Linux on zSeries Development
  Ulrich.Weigand@de.ibm.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]