aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilip Blundell <philb@gnu.org>2004-06-25 21:48:38 +0000
committerMark Mitchell <mmitchel@gcc.gnu.org>2004-06-25 21:48:38 +0000
commit6ef30017a0e7c6855a1e679f6934f65260845b5d (patch)
tree58d45b1a53870f82e8a9f57dacd15ac0107c1b27
parent7619c085c5a7c57e5ce7da32a290bfed82d006b2 (diff)
downloadgcc-6ef30017a0e7c6855a1e679f6934f65260845b5d.zip
gcc-6ef30017a0e7c6855a1e679f6934f65260845b5d.tar.gz
gcc-6ef30017a0e7c6855a1e679f6934f65260845b5d.tar.bz2
re PR tree-optimization/15089 (local register variable with a specified register is bad)
PR wrong-code/15089 * loop.c (scan_loop): Do not move user-specified register assignments. From-SVN: r83684
-rw-r--r--gcc/ChangeLog6
-rw-r--r--gcc/loop.c1
2 files changed, 7 insertions, 0 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index f015ca4..8886dc5 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,9 @@
+2004-06-25 Philip Blundell <philb@gnu.org>
+
+ PR wrong-code/15089
+ * loop.c (scan_loop): Do not move user-specified register
+ assignments.
+
2004-06-25 DJ Delorie <dj@redhat.com>
* c-common.h (warn_cast_qual, warn_missing_format_attribute,
diff --git a/gcc/loop.c b/gcc/loop.c
index aafb18c..28507b3 100644
--- a/gcc/loop.c
+++ b/gcc/loop.c
@@ -931,6 +931,7 @@ scan_loop (struct loop *loop, int flags)
|| (! (REG_P (SET_SRC (set))
&& (REGNO (SET_SRC (set))
< FIRST_PSEUDO_REGISTER))))
+ && regno >= FIRST_PSEUDO_REGISTER
/* This test is not redundant; SET_SRC (set) might be
a call-clobbered register and the life of REGNO
might span a call. */