Re: [DWARF2] CFA in variable location expression

"Momchil Velikov" <>
10 Aug 2002 02:03:38 -0400

          From comp.compilers

Related articles
[DWARF2] CFA in variable location expression (Fred RISS) (2002-08-04)
Re: [DWARF2] CFA in variable location expression (Momchil Velikov) (2002-08-10)
| List of all articles for this month |

From: "Momchil Velikov" <>
Newsgroups: comp.compilers
Date: 10 Aug 2002 02:03:38 -0400
References: 02-08-011
Keywords: debug, linker
Posted-Date: 10 Aug 2002 02:03:38 EDT

"Fred RISS" <> wrote
> I'm looking for a way for a compiler to build a DWARF information that
> indicates a data storage located at a constant offset from the current
> CFA. I don't see such a feature in the standard.

.debug_frame section does not serve as a variable
location information.

> It would be very convenient
> to say instead "Arg1 is at offset x from the current CFA".

See DT_AT_frame_base attribute and the DW_OP_fbreg expressions.
Typically, a function will have in DW_AT_frame_base a single
DW_OP_reg<n> location expression, which would denote the frame pointer
register (or stack pointer, if the frame pointer has been eliminated)
and the DW_OP_fbreg would be exactly the offset from the CFA.


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.