aboutsummaryrefslogtreecommitdiff
path: root/gcc/function.c
diff options
context:
space:
mode:
authorJohn Wehle <john@feith.com>1998-10-12 10:06:49 +0000
committerJeff Law <law@gcc.gnu.org>1998-10-12 04:06:49 -0600
commitfdb8a883a4f3415aec0434737c9446f80d0133f0 (patch)
tree3dfd3a630883b77a0b6ce45c2d90fe9452e85a15 /gcc/function.c
parent3babe36c375f475103415e2ab33b32681b25e8b7 (diff)
downloadgcc-fdb8a883a4f3415aec0434737c9446f80d0133f0.zip
gcc-fdb8a883a4f3415aec0434737c9446f80d0133f0.tar.gz
gcc-fdb8a883a4f3415aec0434737c9446f80d0133f0.tar.bz2
flow.c: Update comment.
* flow.c: Update comment. (notice_stack_pointer_modification): New static function. (record_volatile_insns): Use it. (mark_regs_live_at_end): Mark the stack pointer as alive at the end of the function if current_function_sp_is_unchanging is set. (life_analysis_1): Set current_function_sp_is_unchanging. * function.c: Define it. (init_function_start): Initialize it. * output.h: Declare it. * reorg.c (fill_simple_delay_slots, dbr_schedule): Mark the stack pointer as alive at the end of the function if current_function_sp_is_unchanging is set. * i386.c (ix86_epilogue): Optimize the restoring of the stack pointer. From-SVN: r23009
Diffstat (limited to 'gcc/function.c')
-rw-r--r--gcc/function.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/gcc/function.c b/gcc/function.c
index 4645f5a..48018cf 100644
--- a/gcc/function.c
+++ b/gcc/function.c
@@ -138,6 +138,12 @@ int current_function_has_computed_jump;
int current_function_contains_functions;
+/* Nonzero if function being compiled doesn't modify the stack pointer
+ (ignoring the prologue and epilogue). This is only valid after
+ life_analysis has run. */
+
+int current_function_sp_is_unchanging;
+
/* Nonzero if the current function is a thunk (a lightweight function that
just adjusts one of its arguments and forwards to another function), so
we should try to cut corners where we can. */
@@ -5426,6 +5432,7 @@ init_function_start (subr, filename, line)
current_function_has_nonlocal_label = 0;
current_function_has_nonlocal_goto = 0;
current_function_contains_functions = 0;
+ current_function_sp_is_unchanging = 0;
current_function_is_thunk = 0;
current_function_returns_pcc_struct = 0;