expr.c (convert_move): Use emit_store_flag instead of "emulating" it.
authorPaolo Bonzini <bonzini@gnu.org>
Tue, 7 Apr 2009 12:30:59 +0000 (12:30 +0000)
committerPaolo Bonzini <bonzini@gcc.gnu.org>
Tue, 7 Apr 2009 12:30:59 +0000 (12:30 +0000)
2009-04-07  Paolo Bonzini  <bonzini@gnu.org>

        * expr.c (convert_move): Use emit_store_flag instead of
        "emulating" it.

From-SVN: r145666

gcc/ChangeLog
gcc/expr.c

index 1830f9df2556f7f88895f9b1dc2d9256c465a4d2..8c946ebe3071a00904750199bc3881dcce8afb06 100644 (file)
@@ -1,3 +1,8 @@
+2009-04-07  Paolo Bonzini  <bonzini@gnu.org>
+
+        * expr.c (convert_move): Use emit_store_flag instead of
+        "emulating" it.
+
 2009-04-07  Paolo Bonzini  <bonzini@gnu.org>
 
         * config/i386/i386.c (ix86_compare_emitted): Remove.
index ff3867e59ecc4813970408701c8d622080dc44f0..f25ec7b4b18647c765267fb75821b0130a333c1f 100644 (file)
@@ -588,27 +588,9 @@ convert_move (rtx to, rtx from, int unsignedp)
       if (unsignedp)
        fill_value = const0_rtx;
       else
-       {
-#ifdef HAVE_slt
-         if (HAVE_slt
-             && insn_data[(int) CODE_FOR_slt].operand[0].mode == word_mode
-             && STORE_FLAG_VALUE == -1)
-           {
-             emit_cmp_insn (lowfrom, const0_rtx, NE, NULL_RTX,
-                            lowpart_mode, 0);
-             fill_value = gen_reg_rtx (word_mode);
-             emit_insn (gen_slt (fill_value));
-           }
-         else
-#endif
-           {
-             fill_value
-               = expand_shift (RSHIFT_EXPR, lowpart_mode, lowfrom,
-                               size_int (GET_MODE_BITSIZE (lowpart_mode) - 1),
-                               NULL_RTX, 0);
-             fill_value = convert_to_mode (word_mode, fill_value, 1);
-           }
-       }
+       fill_value = emit_store_flag (gen_reg_rtx (word_mode),
+                                     LT, lowfrom, const0_rtx,
+                                     VOIDmode, 0, -1);
 
       /* Fill the remaining words.  */
       for (i = GET_MODE_SIZE (lowpart_mode) / UNITS_PER_WORD; i < nwords; i++)