From 83a67d12b2fbf92b45e8a4e2c6b77e3c817eeba5 Mon Sep 17 00:00:00 2001 From: Richard Henderson Date: Thu, 27 Apr 2000 00:39:51 -0700 Subject: [PATCH] flow.c (calculate_global_regs_live): Force stack pointer live at end. * flow.c (calculate_global_regs_live): Force stack pointer live at end. From-SVN: r33476 --- gcc/ChangeLog | 3 +++ gcc/flow.c | 4 ++++ 2 files changed, 7 insertions(+) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 4354846d381..055cfbf3327 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -3,6 +3,9 @@ * flow.c (allocate_reg_life_data): Set max_regno here ... (life_analysis): ... not here. + * flow.c (calculate_global_regs_live): Force stack pointer + live at end. + 2000-04-26 Richard Henderson * jump.c (redirect_exp_1): Rework from old redirect_exp. Never diff --git a/gcc/flow.c b/gcc/flow.c index 5a729c77d7d..72a8372e05e 100644 --- a/gcc/flow.c +++ b/gcc/flow.c @@ -3050,6 +3050,10 @@ calculate_global_regs_live (blocks_in, blocks_out, flags) IOR_REG_SET (new_live_at_end, sb->global_live_at_start); } + /* Force the stack pointer to be live -- which might not already be + the case for blocks within infinite loops. */ + SET_REGNO_REG_SET (new_live_at_end, STACK_POINTER_REGNUM); + /* Regs used in phi nodes are not included in global_live_at_start, since they are live only along a particular edge. Set those regs that are live because of a -- 2.30.2