diff options
author | Richard Henderson <rth@redhat.com> | 2005-11-17 17:19:10 -0800 |
---|---|---|
committer | Richard Henderson <rth@gcc.gnu.org> | 2005-11-17 17:19:10 -0800 |
commit | f6672e8e52276dcaf1a27e636247383f316ce221 (patch) | |
tree | c03bdda31c81403f3bcd5fcf610248b9f27ee02a /gcc/function.c | |
parent | ca9e049bc145ae985bc0e2dd6079dacdd51717ac (diff) | |
download | gcc-f6672e8e52276dcaf1a27e636247383f316ce221.zip gcc-f6672e8e52276dcaf1a27e636247383f316ce221.tar.gz gcc-f6672e8e52276dcaf1a27e636247383f316ce221.tar.bz2 |
dwarf2out.c (dw_cfi_oprnd_struct): Reduce dw_cfi_reg_num to int.
* dwarf2out.c (dw_cfi_oprnd_struct): Reduce dw_cfi_reg_num to int.
(lookup_cfa_1): Apply data alignment to DW_CFA_def_cfa_offset_sf
and DW_CFA_def_cfa_sf.
(def_cfa_1): Use DW_CFA_def_cfa_offset_sf with negative values.
(dbx_reg_number): Don't assert particular registers here.
(based_loc_descr): ... do it here instead. Fold in ...
(eliminate_reg_to_offset): ... this function.
(compute_frame_pointer_to_cfa_displacement): Fold in the effects
of eliminate_reg_to_offset; use FRAME_POINTER_CFA_OFFSET.
* unwind-dw2.c (execute_cfa_program): Apply data align factor
to DW_CFA_def_cfa_offset_sf and DW_CFA_def_cfa_sf.
* function.c (instantiate_new_reg): Use FRAME_POINTER_CFA_OFFSET.
(instantiate_virtual_regs): Likewise.
* var-tracking.c (adjust_stack_reference): Likewise.
* doc/tm.texi (FRAME_POINTER_CFA_OFFSET): New.
From-SVN: r107154
Diffstat (limited to 'gcc/function.c')
-rw-r--r-- | gcc/function.c | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/gcc/function.c b/gcc/function.c index dbf9df7..c0339b8 100644 --- a/gcc/function.c +++ b/gcc/function.c @@ -1246,7 +1246,14 @@ instantiate_new_reg (rtx x, HOST_WIDE_INT *poffset) else if (x == virtual_outgoing_args_rtx) new = stack_pointer_rtx, offset = out_arg_offset; else if (x == virtual_cfa_rtx) - new = arg_pointer_rtx, offset = cfa_offset; + { +#ifdef FRAME_POINTER_CFA_OFFSET + new = frame_pointer_rtx; +#else + new = arg_pointer_rtx; +#endif + offset = cfa_offset; + } else return NULL_RTX; @@ -1632,7 +1639,11 @@ instantiate_virtual_regs (void) var_offset = STARTING_FRAME_OFFSET; dynamic_offset = STACK_DYNAMIC_OFFSET (current_function_decl); out_arg_offset = STACK_POINTER_OFFSET; +#ifdef FRAME_POINTER_CFA_OFFSET + cfa_offset = FRAME_POINTER_CFA_OFFSET (current_function_decl); +#else cfa_offset = ARG_POINTER_CFA_OFFSET (current_function_decl); +#endif /* Initialize recognition, indicating that volatile is OK. */ init_recog (); |