(store_fixed_bit_field): Delete code to handle MODE_FLOAT values here.
authorJim Wilson <wilson@gcc.gnu.org>
Wed, 11 May 1994 21:50:11 +0000 (14:50 -0700)
committerJim Wilson <wilson@gcc.gnu.org>
Wed, 11 May 1994 21:50:11 +0000 (14:50 -0700)
(store_fixed_bit_field): Delete code to handle
MODE_FLOAT values here.
(store_bit_field): Put it here instead.

From-SVN: r7279

gcc/expmed.c

index 8c23d8c8933b79980a42bd35aaa3e86a615a6687..85cf0dec5200ee0553aa7266007a826807412618 100644 (file)
@@ -350,6 +350,17 @@ store_bit_field (str_rtx, bitsize, bitnum, fieldmode, value, align, total_size)
       op0 = protect_from_queue (op0, 1);
     }
 
+  /* If VALUE is a floating-point mode, access it as an integer of the
+     corresponding size.  This can occur on a machine with 64 bit registers
+     that uses SFmode for float.  This can also occur for unaligned float
+     structure fields.  */
+  if (GET_MODE_CLASS (GET_MODE (value)) == MODE_FLOAT)
+    {
+      if (GET_CODE (value) != REG)
+       value = copy_to_reg (value);
+      value = gen_rtx (SUBREG, word_mode, value, 0);
+    }
+
   /* Now OFFSET is nonzero only if OP0 is memory
      and is therefore always measured in bytes.  */
 
@@ -520,17 +531,6 @@ store_fixed_bit_field (op0, offset, bitsize, bitpos, value, struct_align)
   int all_zero = 0;
   int all_one = 0;
 
-  /* If VALUE is a floating-point mode, access it as an integer of the
-     corresponding size.  This can occur on a machine with 64 bit registers
-     that uses SFmode for float.  This can also occur for unaligned float
-     structure fields.  */
-  if (GET_MODE_CLASS (GET_MODE (value)) == MODE_FLOAT)
-    {
-      if (GET_CODE (value) != REG)
-       value = copy_to_reg (value);
-      value = gen_rtx (SUBREG, word_mode, value, 0);
-    }
-
   /* There is a case not handled here:
      a structure with a known alignment of just a halfword
      and a field split across two aligned halfwords within the structure.