]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
* gcse.c (hash_scan_set): Expressions that are set as part of
authorgeoffk <geoffk@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 13 Aug 2001 21:42:10 +0000 (21:42 +0000)
committergeoffk <geoffk@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 13 Aug 2001 21:42:10 +0000 (21:42 +0000)
jump instructions are not available.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@44872 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ChangeLog
gcc/gcse.c

index 20017ca5510c7c00596405fda284247c336b9f2f..80ab091ed0a2a25fd9d9b4fec8d0c9090d55383d 100644 (file)
@@ -1,3 +1,8 @@
+2001-08-13  Geoffrey Keating  <geoffk@redhat.com>
+
+       * gcse.c (hash_scan_set): Expressions that are set as part of
+       jump instructions are not available.
+
 2001-08-13  Ulrich Weigand  <uweigand@de.ibm.com>
 
        * config/s390/s390.c (print_operand, s390_function_prologue,
index 0c1bc3c835a741c3884bd26a6dfb523f52a59e3b..8164ee3e2c12db4bbd0c3ccfd5bf4363a5154347 100644 (file)
@@ -2191,8 +2191,11 @@ hash_scan_set (pat, insn, set_p)
             this insn.  */
          int antic_p = oprs_anticipatable_p (src, insn) && single_set (insn);
          /* An expression is not available if its operands are
-            subsequently modified, including this insn.  */
-         int avail_p = oprs_available_p (src, insn);
+            subsequently modified, including this insn.  It's also not
+            available if this is a branch, because we can't insert
+            a set after the branch.  */
+         int avail_p = (oprs_available_p (src, insn)
+                        && ! JUMP_P (insn));
 
          insert_expr_in_table (src, GET_MODE (dest), insn, antic_p, avail_p);
        }