sparc.md (TFmode splits): Use reg_overlap_mentioned_p to detect when the source and...
authorJeffrey A Law <law@cygnus.com>
Mon, 24 Aug 1998 10:01:01 +0000 (10:01 +0000)
committerJeff Law <law@gcc.gnu.org>
Mon, 24 Aug 1998 10:01:01 +0000 (04:01 -0600)
        * sparc.md (TFmode splits): Use reg_overlap_mentioned_p to detect
        when the source and destination overlap.

From-SVN: r21933

gcc/ChangeLog
gcc/config/sparc/sparc.md

index 2c73cf8..10f8e26 100644 (file)
@@ -1,5 +1,8 @@
 Mon Aug 24 10:25:46 1998  Jeffrey A Law  (law@cygnus.com)
 
+       * sparc.md (TFmode splits): Use reg_overlap_mentioned_p to detect
+       when the source and destination overlap.
+
        * stmt.c (emit_case_nodes): Change rtx_function to rtx_fn to avoid
        clash with global type.
 
index 558d15a..003e39e 100644 (file)
 
   /* Now emit using the real source and destination we found, swapping
      the order if we detect overlap.  */
-  if (REGNO (dest1) == REGNO (src2))
+  if (reg_overlap_mentioned_p (dest1, src2))
     {
       emit_insn (gen_movsi (dest2, src2));
       emit_insn (gen_movsi (dest1, src1));
   rtx low_part = gen_lowpart (SImode, operands[0]);
   int self_reference;
 
-  self_reference = reg_mentioned_p (operands[0],
-                                    XEXP (XEXP (word1, 0), 0));
+  self_reference = reg_overlap_mentioned_p (operands[0],
+                                           XEXP (XEXP (word1, 0), 0));
   if (self_reference != 0
       && WORDS_BIG_ENDIAN)
     {
 
   /* Now emit using the real source and destination we found, swapping
      the order if we detect overlap.  */
-  if (REGNO(dest1) == REGNO(src2))
+  if (reg_overlap_mentioned_p (dest1, src2))
     {
       emit_insn (gen_movsf (dest2, src2));
       emit_insn (gen_movsf (dest1, src1));
                              plus_constant_for_output (XEXP (word0, 0), 4));
   int self_reference;
 
-  self_reference = reg_mentioned_p (operands[0],
-                                    XEXP (XEXP (word1, 0), 0));
+  self_reference = reg_overlap_mentioned_p (operands[0],
+                                           XEXP (XEXP (word1, 0), 0));
   if (GET_CODE (operands[0]) == SUBREG)
     operands[0] = alter_subreg (operands[0]);
 
 
   /* Now emit using the real source and destination we found, swapping
      the order if we detect overlap.  */
-  if (REGNO(dest1) == REGNO(src2))
+  if (reg_overlap_mentioned_p (dest1, src2))
     {
       emit_insn (gen_movdf (dest2, src2));
       emit_insn (gen_movdf (dest1, src1));
   rtx word1 = change_address (operands[1], DFmode,
                              plus_constant_for_output (XEXP (word0, 0), 8));
   rtx dest1, dest2;
-  int self_reference = reg_mentioned_p (operands[0],
-                                        XEXP (XEXP (word1, 0), 0));
+  int self_reference = reg_overlap_mentioned_p (operands[0],
+                                               XEXP (XEXP (word1, 0), 0));
 
   /* Ugly, but gen_highpart will crap out here for 32-bit targets.  */
   dest1 = gen_rtx_SUBREG (DFmode, operands[0], WORDS_BIG_ENDIAN == 0);