aboutsummaryrefslogtreecommitdiff
path: root/gcc/function.c
diff options
context:
space:
mode:
authorRichard Henderson <rth@redhat.com>2004-07-23 15:37:23 -0700
committerRichard Henderson <rth@gcc.gnu.org>2004-07-23 15:37:23 -0700
commitab8907ef75b71c987932a299bddf04cb73907c69 (patch)
tree6fa3fcbf916c4e6bd0c3081ee4de2cf5ae950925 /gcc/function.c
parent5aa33bdb4f75939b9467a4580aa13bb6997f192c (diff)
downloadgcc-ab8907ef75b71c987932a299bddf04cb73907c69.zip
gcc-ab8907ef75b71c987932a299bddf04cb73907c69.tar.gz
gcc-ab8907ef75b71c987932a299bddf04cb73907c69.tar.bz2
expr.c (expand_expr_real_1): Don't handle non-local variables.
* expr.c (expand_expr_real_1): Don't handle non-local variables. * expr.h (fix_lexical_addr): Remove. * function.c (NEED_SEPARATE_AP): Remove. (fix_lexical_addr): Remove. * tree-alias-common.c (get_alias_var_decl): Check TREE_STATIC, not null decl_function_context. (create_alias_vars): Likewise. * tree-cfg.c (make_ctrl_stmt_edges): Don't check for non-local labels. (simple_goto_p): Likewise. * tree-dfa.c (add_referenced_var): Don't check for non-local variables. * tree-ssa-ccp.c (get_default_value): Likewise. * tree-tailcall.c (suitable_for_tail_opt_p): Likewise. * tree.c (needs_to_live_in_memory): Likewise. * tree-flow-inline.h (may_be_aliased): Move... * tree-ssa-alias.c (may_be_aliased): ... here. Enhance check for when TREE_STATIC variables may be addressable. From-SVN: r85099
Diffstat (limited to 'gcc/function.c')
-rw-r--r--gcc/function.c45
1 files changed, 0 insertions, 45 deletions
diff --git a/gcc/function.c b/gcc/function.c
index 23fb74c..956fa76 100644
--- a/gcc/function.c
+++ b/gcc/function.c
@@ -87,16 +87,6 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
alignment. */
#define CEIL_ROUND(VALUE,ALIGN) (((VALUE) + (ALIGN) - 1) & ~((ALIGN)- 1))
-/* NEED_SEPARATE_AP means that we cannot derive ap from the value of fp
- during rtl generation. If they are different register numbers, this is
- always true. It may also be true if
- FIRST_PARM_OFFSET - STARTING_FRAME_OFFSET is not a constant during rtl
- generation. See fix_lexical_addr for details. */
-
-#if ARG_POINTER_REGNUM != FRAME_POINTER_REGNUM
-#define NEED_SEPARATE_AP
-#endif
-
/* Nonzero if function being compiled doesn't contain any calls
(ignoring the prologue and epilogue). This is set prior to
local register allocation and is valid for the remaining
@@ -3571,41 +3561,6 @@ setjmp_args_warning (void)
}
-/* Convert a stack slot address ADDR for variable VAR
- (from a containing function)
- into an address valid in this function (using a static chain). */
-
-rtx
-fix_lexical_addr (rtx addr, tree var)
-{
- rtx basereg;
- HOST_WIDE_INT displacement;
- tree context = decl_function_context (var);
- struct function *fp;
- rtx base = 0;
-
- /* If this is the present function, we need not do anything. */
- if (context == current_function_decl)
- return addr;
-
- fp = find_function_data (context);
-
- /* Decode given address as base reg plus displacement. */
- if (REG_P (addr))
- basereg = addr, displacement = 0;
- else if (GET_CODE (addr) == PLUS && GET_CODE (XEXP (addr, 1)) == CONST_INT)
- basereg = XEXP (addr, 0), displacement = INTVAL (XEXP (addr, 1));
- else
- abort ();
-
- if (base == 0)
- abort ();
-
- /* Use same offset, relative to appropriate static chain or argument
- pointer. */
- return plus_constant (base, displacement);
-}
-
/* Identify BLOCKs referenced by more than one NOTE_INSN_BLOCK_{BEG,END},
and create duplicate blocks. */
/* ??? Need an option to either create block fragments or to create