]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
(cse_insn): Set src_eqv if the dest is a STRICT_LOW_PART.
authorJim Wilson <wilson@gcc.gnu.org>
Wed, 11 May 1994 21:44:22 +0000 (14:44 -0700)
committerJim Wilson <wilson@gcc.gnu.org>
Wed, 11 May 1994 21:44:22 +0000 (14:44 -0700)
From-SVN: r7278

gcc/cse.c

index 88454035bcfcd5d57e3ecee26360f8d7f1e6dff2..926f06b68a02379c1b52b112550b3ccc6b4a5259 100644 (file)
--- a/gcc/cse.c
+++ b/gcc/cse.c
@@ -6044,10 +6044,14 @@ cse_insn (insn, in_libcall_block)
       fold_rtx (x, insn);
     }
 
-  /* Store the equivalent value in SRC_EQV, if different.  */
+  /* Store the equivalent value in SRC_EQV, if different, or if the DEST
+     is a STRICT_LOW_PART.  The latter condition is necessary because SRC_EQV
+     is handled specially for this case, and if it isn't set, then there will
+     be no equivalence for the destinatation.  */
   if (n_sets == 1 && REG_NOTES (insn) != 0
       && (tem = find_reg_note (insn, REG_EQUAL, NULL_RTX)) != 0
-      && ! rtx_equal_p (XEXP (tem, 0), SET_SRC (sets[0].rtl)))
+      && (! rtx_equal_p (XEXP (tem, 0), SET_SRC (sets[0].rtl))
+         || GET_CODE (SET_DEST (sets[0].rtl)) == STRICT_LOW_PART))
     src_eqv = canon_reg (XEXP (tem, 0), NULL_RTX);
 
   /* Canonicalize sources and addresses of destinations.