From: David S. Miller Date: Fri, 2 Oct 1998 20:17:50 +0000 (+0000) Subject: function.c (purge_addressof_1): Do not perform endianness corrections on bitpos,... X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=47401c4d4bb3b037324a314f183297502c1cb3d4;p=gcc.git function.c (purge_addressof_1): Do not perform endianness corrections on bitpos, who we call will do it for us. * function.c (purge_addressof_1): Do not perform endianness corrections on bitpos, who we call will do it for us. From-SVN: r22766 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index fcb480e0636..efcfefa0829 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +Fri Oct 2 19:14:20 1998 David S. Miller + + * function.c (purge_addressof_1): Do not perform endianness + corrections on bitpos, who we call will do it for us. + Fri Oct 2 11:52:35 1998 Jeffrey A Law (law@cygnus.com) * h8300.c (WORD_REG_USED): Fix typo. diff --git a/gcc/function.c b/gcc/function.c index d4f29dbf73f..41f400e1c52 100644 --- a/gcc/function.c +++ b/gcc/function.c @@ -2879,21 +2879,8 @@ purge_addressof_1 (loc, insn, force, store) /* Do a bitfield insertion to mirror what would happen in memory. */ - int bitpos; rtx val, seq; - bitpos = 0; - if (WORDS_BIG_ENDIAN) - { - bitpos += (size_sub / BITS_PER_WORD) * BITS_PER_WORD; - bitpos -= (size_x / BITS_PER_WORD) * BITS_PER_WORD; - } - if (BYTES_BIG_ENDIAN) - { - bitpos += size_sub % BITS_PER_WORD; - bitpos -= size_x % BITS_PER_WORD; - } - if (store) { /* If we can't replace with a register, be afraid. */ @@ -2907,7 +2894,7 @@ purge_addressof_1 (loc, insn, force, store) emit_insn_before (seq, insn); start_sequence (); - store_bit_field (sub, size_x, bitpos, GET_MODE (x), + store_bit_field (sub, size_x, 0, GET_MODE (x), val, GET_MODE_SIZE (GET_MODE (sub)), GET_MODE_SIZE (GET_MODE (sub))); @@ -2918,7 +2905,7 @@ purge_addressof_1 (loc, insn, force, store) else { start_sequence (); - val = extract_bit_field (sub, size_x, bitpos, 1, NULL_RTX, + val = extract_bit_field (sub, size_x, 0, 1, NULL_RTX, GET_MODE (x), GET_MODE (x), GET_MODE_SIZE (GET_MODE (sub)), GET_MODE_SIZE (GET_MODE (sub)));