]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
re PR target/18004 (ICE in output_constant_pool_2 for aligned(1) float in struct)
authorGabriel Dos Reis <gdr@integrable-solutions.net>
Sat, 30 Apr 2005 16:01:29 +0000 (16:01 +0000)
committerGabriel Dos Reis <gdr@gcc.gnu.org>
Sat, 30 Apr 2005 16:01:29 +0000 (16:01 +0000)
* Apply:
2004-10-21  Aldy Hernandez  <aldyh@redhat.com>

PR target/18004.
* expmed.c (store_bit_field): Pass original 'value' before
recursing.

From-SVN: r99036

gcc/ChangeLog
gcc/expmed.c

index 597f907c9d11794694f9c9e07a16dcf72ef28860..b675b1cb2814836b405149e94cfd538f36c98c2e 100644 (file)
@@ -1,3 +1,12 @@
+2005-04-30  Gabriel Dos Reis  <gdr@integrable-solutions.net>
+
+       * Apply:
+       2004-10-21  Aldy Hernandez  <aldyh@redhat.com>
+
+       PR target/18004.
+       * expmed.c (store_bit_field): Pass original 'value' before
+       recursing.
+
 2005-04-22  Eric Botcazou  <ebotcazou@libertysurf.fr>
 
        * doc/invoke.texi (SPARC options): Document that -mapp-regs
index 2274bdaacb0e9a7c818c790081635f22bd68b25d..72ef6cef30700db0ebda423b79e5bb98612b776b 100644 (file)
@@ -299,6 +299,7 @@ store_bit_field (str_rtx, bitsize, bitnum, fieldmode, value, total_size)
   unsigned HOST_WIDE_INT bitpos = bitnum % unit;
   rtx op0 = str_rtx;
   int byte_offset;
+  rtx orig_value;
 
   enum machine_mode op_mode = mode_for_extraction (EP_insv, 3);
 
@@ -532,6 +533,7 @@ store_bit_field (str_rtx, bitsize, bitnum, fieldmode, value, total_size)
      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.  */
+  orig_value = value;
   if (GET_MODE_CLASS (GET_MODE (value)) != MODE_INT
       && GET_MODE_CLASS (GET_MODE (value)) != MODE_PARTIAL_INT)
     value = gen_lowpart ((GET_MODE (value) == VOIDmode
@@ -598,7 +600,7 @@ store_bit_field (str_rtx, bitsize, bitnum, fieldmode, value, total_size)
          /* Fetch that unit, store the bitfield in it, then store
             the unit.  */
          tempreg = copy_to_reg (op0);
-         store_bit_field (tempreg, bitsize, bitpos, fieldmode, value,
+         store_bit_field (tempreg, bitsize, bitpos, fieldmode, orig_value,
                           total_size);
          emit_move_insn (op0, tempreg);
          return value;