Commit c410d49e by Eric Christopher

expmed.c (store_bit_field): Try to simplify the subreg before generating a new one when...

2002-02-21  Eric Christopher  <echristo@redhat.com>

	* expmed.c (store_bit_field): Try to simplify the subreg
	before generating a new one when when the mode size of
	value is less than maxmode.

From-SVN: r49946
parent e3c8ea67
2002-02-21 Eric Christopher <echristo@redhat.com>
* expmed.c (store_bit_field): Try to simplify the subreg
before generating a new one when when the mode size of
value is less than maxmode.
2002-02-21 Richard Henderson <rth@redhat.com>
* emit-rtl.c (offset_address): Use simplify_gen_binary rather
......
......@@ -630,8 +630,17 @@ store_bit_field (str_rtx, bitsize, bitnum, fieldmode, value, total_size)
if we must narrow it, be sure we do it correctly. */
if (GET_MODE_SIZE (GET_MODE (value)) < GET_MODE_SIZE (maxmode))
value1 = simplify_gen_subreg (maxmode, value1,
GET_MODE (value1), 0);
{
rtx tmp;
tmp = simplify_subreg (maxmode, value1, GET_MODE (value), 0);
if (! tmp)
tmp = simplify_gen_subreg (maxmode,
force_reg (GET_MODE (value),
value1),
GET_MODE (value), 0);
value1 = tmp;
}
else
value1 = gen_lowpart (maxmode, value1);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment