explow.c (plus_constant): Pass "mode" to immed_double_int_const.

gcc/
	* explow.c (plus_constant): Pass "mode" to immed_double_int_const.
	Use gen_int_mode rather than GEN_INT.

From-SVN: r198462
This commit is contained in:
Richard Sandiford 2013-04-30 16:15:55 +00:00 committed by Richard Sandiford
parent b0dec60747
commit d6b2815614
2 changed files with 8 additions and 3 deletions

View file

@ -1,3 +1,8 @@
2013-04-30 Richard Sandiford <rsandifo@linux.vnet.ibm.com>
* explow.c (plus_constant): Pass "mode" to immed_double_int_const.
Use gen_int_mode rather than GEN_INT.
2013-04-30 H.J. Lu <hongjiu.lu@intel.com>
* value-prof.c (stream_in_histogram_value): Remove the strayed

View file

@ -106,10 +106,10 @@ plus_constant (enum machine_mode mode, rtx x, HOST_WIDE_INT c)
if (overflow)
gcc_unreachable ();
return immed_double_int_const (v, VOIDmode);
return immed_double_int_const (v, mode);
}
return GEN_INT (INTVAL (x) + c);
return gen_int_mode (INTVAL (x) + c, mode);
case CONST_DOUBLE:
{
@ -124,7 +124,7 @@ plus_constant (enum machine_mode mode, rtx x, HOST_WIDE_INT c)
To fix, add constant support wider than CONST_DOUBLE. */
gcc_assert (GET_MODE_BITSIZE (mode) <= HOST_BITS_PER_DOUBLE_INT);
return immed_double_int_const (v, VOIDmode);
return immed_double_int_const (v, mode);
}
case MEM: