Commit a6d2976a by John David Anglin Committed by John David Anglin

re PR middle-end/19330 (FAIL: gcc.c-torture/execute/20010605-2.c execution, -O1)

	PR middle-end/19330
	* expmed.c (extract_bit_field): Use adjust_address instead of
	gen_lowpart when op0 is a MEM.

From-SVN: r94198
parent 83c8f106
2005-01-24 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
PR middle-end/19330
* expmed.c (extract_bit_field): Use adjust_address instead of
gen_lowpart when op0 is a MEM.
2005-01-24 Steven Bosscher <stevenb@suse.de> 2005-01-24 Steven Bosscher <stevenb@suse.de>
* cfgexpand.c (expand_gimple_tailcall): Fix typo. * cfgexpand.c (expand_gimple_tailcall): Fix typo.
......
...@@ -1158,12 +1158,18 @@ extract_bit_field (rtx str_rtx, unsigned HOST_WIDE_INT bitsize, ...@@ -1158,12 +1158,18 @@ extract_bit_field (rtx str_rtx, unsigned HOST_WIDE_INT bitsize,
enum machine_mode imode = int_mode_for_mode (GET_MODE (op0)); enum machine_mode imode = int_mode_for_mode (GET_MODE (op0));
if (imode != GET_MODE (op0)) if (imode != GET_MODE (op0))
{ {
op0 = gen_lowpart (imode, op0); if (MEM_P (op0))
op0 = adjust_address (op0, imode, 0);
else
{
gcc_assert (imode != BLKmode);
op0 = gen_lowpart (imode, op0);
/* If we got a SUBREG, force it into a register since we aren't going /* If we got a SUBREG, force it into a register since we
to be able to do another SUBREG on it. */ aren't going to be able to do another SUBREG on it. */
if (GET_CODE (op0) == SUBREG) if (GET_CODE (op0) == SUBREG)
op0 = force_reg (imode, op0); op0 = force_reg (imode, op0);
}
} }
} }
......
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