diff options
author | aoliva <aoliva@138bc75d-0d04-0410-961f-82ee72b054a4> | 2000-12-15 09:09:41 +0000 |
---|---|---|
committer | aoliva <aoliva@138bc75d-0d04-0410-961f-82ee72b054a4> | 2000-12-15 09:09:41 +0000 |
commit | 3f27e1986c496f898d759b19763b348037c294d5 (patch) | |
tree | ac2831caf34906c434220747ac02464ced602994 /gcc/function.c | |
parent | 527268152f73e097f784e9b9212a7be57aeebb38 (diff) | |
download | gcc-3f27e1986c496f898d759b19763b348037c294d5.tar.gz |
* function.c (adjust_trampoline_addr): New function.
(trampoline_address): Call it instead of round_trampoline_addr().
* tm.texi (TRAMPOLINE_ADJUST_ADDRESS): Document it.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@38279 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/function.c')
-rw-r--r-- | gcc/function.c | 22 |
1 files changed, 19 insertions, 3 deletions
diff --git a/gcc/function.c b/gcc/function.c index 07992162067..d2ce5b54c4b 100644 --- a/gcc/function.c +++ b/gcc/function.c @@ -279,6 +279,7 @@ static void pad_below PARAMS ((struct args_size *, enum machine_mode, tree)); #endif static rtx round_trampoline_addr PARAMS ((rtx)); +static rtx adjust_trampoline_addr PARAMS ((rtx)); static tree *identify_blocks_1 PARAMS ((rtx, tree *, tree *, tree *)); static void reorder_blocks_1 PARAMS ((rtx, tree, varray_type *)); static tree blocks_nreverse PARAMS ((tree)); @@ -5553,7 +5554,7 @@ trampoline_address (function) for (link = trampoline_list; link; link = TREE_CHAIN (link)) if (TREE_PURPOSE (link) == function) return - round_trampoline_addr (XEXP (RTL_EXPR_RTL (TREE_VALUE (link)), 0)); + adjust_trampoline_addr (XEXP (RTL_EXPR_RTL (TREE_VALUE (link)), 0)); for (fp = outer_function_chain; fp; fp = fp->next) for (link = fp->x_trampoline_list; link; link = TREE_CHAIN (link)) @@ -5561,7 +5562,7 @@ trampoline_address (function) { tramp = fix_lexical_addr (XEXP (RTL_EXPR_RTL (TREE_VALUE (link)), 0), function); - return round_trampoline_addr (tramp); + return adjust_trampoline_addr (tramp); } /* None exists; we must make one. */ @@ -5612,7 +5613,7 @@ trampoline_address (function) } tramp = fix_lexical_addr (XEXP (tramp, 0), function); - return round_trampoline_addr (tramp); + return adjust_trampoline_addr (tramp); } /* Given a trampoline address, @@ -5634,6 +5635,21 @@ round_trampoline_addr (tramp) #endif return tramp; } + +/* Given a trampoline address, round it then apply any + platform-specific adjustments so that the result can be used for a + function call . */ + +static rtx +adjust_trampoline_addr (tramp) + rtx tramp; +{ + tramp = round_trampoline_addr (tramp); +#ifdef TRAMPOLINE_ADJUST_ADDRESS + TRAMPOLINE_ADJUST_ADDRESS (tramp); +#endif + return tramp; +} /* Put all this function's BLOCK nodes including those that are chained onto the first block into a vector, and return it. |