From 29db2a1e1cc1f95d3d3e1782b6f5dfc16a8bad46 Mon Sep 17 00:00:00 2001 From: "J\"orn Rennecke" Date: Tue, 18 Feb 2003 20:20:11 +0000 Subject: [PATCH] sh.c (calc_live_regs): Also check GET_CODE when checking if initial value for PR_REG is still the... * sh.c (calc_live_regs): Also check GET_CODE when checking if initial value for PR_REG is still the PR_REG register. From-SVN: r63064 --- gcc/ChangeLog | 5 +++++ gcc/config/sh/sh.c | 4 +++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index b23bec7..e7529f1 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +Tue Feb 18 20:15:54 2003 J"orn Rennecke + + * sh.c (calc_live_regs): Also check GET_CODE when checking if initial value + for PR_REG is still the PR_REG register. + 2003-02-18 Jim Wilson * config/ia64/ia64.md (floatdidf2, floatdisf2): Add %, before second diff --git a/gcc/config/sh/sh.c b/gcc/config/sh/sh.c index b1df940..0bb0d94 100644 --- a/gcc/config/sh/sh.c +++ b/gcc/config/sh/sh.c @@ -4571,7 +4571,9 @@ calc_live_regs (count_ptr, live_regs_mask) { rtx pr_initial = has_hard_reg_initial_val (Pmode, PR_REG); pr_live = (pr_initial - ? REGNO (pr_initial) != (PR_REG) : regs_ever_live[PR_REG]); + ? (GET_CODE (pr_initial) != REG + || REGNO (pr_initial) != (PR_REG)) + : regs_ever_live[PR_REG]); } /* Force PR to be live if the prologue has to call the SHmedia argument decoder or register saver. */ -- 2.7.4