OSDN Git Service

* gcc.dg/pragma-darwin.c: Improve for ppc64.
[pf3gnuchains/gcc-fork.git] / gcc / rtlhooks.c
index bc41398..ece7198 100644 (file)
@@ -44,9 +44,12 @@ gen_lowpart_general (enum machine_mode mode, rtx x)
 
   if (result)
     return result;
-  else if (REG_P (x))
+  /* If it's a REG, it must be a hard reg that's not valid in MODE.  */
+  else if (REG_P (x)
+          /* Or we could have a subreg of a floating point value.  */
+          || (GET_CODE (x) == SUBREG
+              && FLOAT_MODE_P (GET_MODE (SUBREG_REG (x)))))
     {
-      /* Must be a hard reg that's not valid in MODE.  */
       result = gen_lowpart_common (mode, copy_to_reg (x));
       gcc_assert (result != 0);
       return result;
@@ -114,6 +117,13 @@ reg_nonzero_bits_general (rtx x ATTRIBUTE_UNUSED,
   return NULL;
 }
 
+bool
+reg_truncated_to_mode_general (enum machine_mode mode ATTRIBUTE_UNUSED,
+                              rtx x ATTRIBUTE_UNUSED)
+{
+  return false;
+}
+
 /* Assuming that X is an rtx (e.g., MEM, REG or SUBREG) for a fixed-point
    number, return an rtx (MEM, SUBREG, or CONST_INT) that refers to the
    least-significant part of X.