* cse.c (cse_insn): Never prefer (const (constant_p_rtx)).
authorRichard Henderson <rth@cygnus.com>
Tue, 12 Jan 1999 02:54:32 +0000 (18:54 -0800)
committerRichard Henderson <rth@gcc.gnu.org>
Tue, 12 Jan 1999 02:54:32 +0000 (18:54 -0800)
From-SVN: r24637

gcc/ChangeLog
gcc/cse.c

index c39187b13ae69c8d2c666f3300526619d5a6fe1a..fc4996c540637787dd975b8bb3c471510eb27d8a 100644 (file)
@@ -1,3 +1,7 @@
+Tue Jan 12 02:53:46 1999  Richard Henderson  <rth@cygnus.com>
+
+       * cse.c (cse_insn): Never prefer (const (constant_p_rtx)).
+
 Tue Jan 12 02:36:10 PST 1999 Jeff Law  (law@cygnus.com)
 
        * version.c: Bump for snapshot.
index 0d8fc4aeae0eeb0bb6be8ca6868d41b91a44449b..4ba247ce3ce8b28d5ab7f059037d689a2cafa653 100644 (file)
--- a/gcc/cse.c
+++ b/gcc/cse.c
@@ -6865,6 +6865,12 @@ cse_insn (insn, libcall_insn)
       if (src == src_folded)
         src_folded = 0;
 
+      /* Folds of constant_p_rtx are to be preferred, since we do
+        not wish any to live past CSE.  */
+      if (src && GET_CODE (src) == CONST
+         && GET_CODE (XEXP (src, 0)) == CONSTANT_P_RTX)
+       src = 0;
+
       /* At this point, ELT, if non-zero, points to a class of expressions
          equivalent to the source of this SET and SRC, SRC_EQV, SRC_FOLDED,
         and SRC_RELATED, if non-zero, each contain additional equivalent