From 78ef1e3d9fbe214ead3c117ec54a5c10da91a0df Mon Sep 17 00:00:00 2001 From: Richard Henderson Date: Wed, 26 Jan 2005 15:18:14 -0800 Subject: re PR middle-end/18008 (Duplicate mask on bitfield insertion) PR middle-end/18008 * c-decl.c (finish_struct): Set DECL_MODE after resetting a field's type. * expmed.c (store_fixed_bit_field): Create a paradoxical subreg if we don't need the bits above those present in the current mode. * expr.c (store_field): Strip conversions to odd-bit-sized types if the destination field width matches. From-SVN: r94290 --- gcc/expmed.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'gcc/expmed.c') diff --git a/gcc/expmed.c b/gcc/expmed.c index 1091c45..084a987 100644 --- a/gcc/expmed.c +++ b/gcc/expmed.c @@ -878,7 +878,7 @@ store_fixed_bit_field (rtx op0, unsigned HOST_WIDE_INT offset, if (GET_MODE (value) != mode) { if ((REG_P (value) || GET_CODE (value) == SUBREG) - && GET_MODE_SIZE (mode) < GET_MODE_SIZE (GET_MODE (value))) + && GET_MODE_SIZE (GET_MODE (value)) <= bitsize) value = gen_lowpart (mode, value); else value = convert_to_mode (mode, value, 1); -- cgit v1.1