Commit ae15736e by Joern Rennecke Committed by Joern Rennecke

re PR target/44757 (lm32.md: In function ‘gen_ashlsi3’:unused variable ‘one’)

2010-11-08  Joern Rennecke  <amylaar@spamcop.net>
	    Richard Henderson <rth@redhat.com>

	PR target/44757 
	* config/lm32/lm32.h (LEGITIMATE_CONSTANT_P): Call
	lm32_legitimate_constant_p.
	* config/lm32/lm32.md (ashlsi3): Remove unused variable.
	* config/lm32/lm32.c (gen_int_relational): Make new block for
	LE / LT / LEU / LTU case.  Declare variables at start of block.
	(lm32_block_move_inline): Use XALLOCAVEC.

Co-Authored-By: Richard Henderson <rth@redhat.com>

From-SVN: r166451
parent f4becba8
......@@ -39,6 +39,14 @@
(bdesc_void3arg, bdesc_voidacc, bdesc_loads, bdesc_stores): Likewise.
(frv_read_argument): Use expand_normal.
PR target/44757
* config/lm32/lm32.h (LEGITIMATE_CONSTANT_P): Call
lm32_legitimate_constant_p.
* config/lm32/lm32.md (ashlsi3): Remove unused variable.
* config/lm32/lm32.c (gen_int_relational): Make new block for
LE / LT / LEU / LTU case. Declare variables at start of block.
(lm32_block_move_inline): Use XALLOCAVEC.
2010-11-08 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
* config/i386/i386.c (ix86_function_arg_boundary): Fix warning
......@@ -191,18 +191,22 @@ gen_int_relational (enum rtx_code code,
case LT:
case LEU:
case LTU:
code = swap_condition (code);
rtx temp = cmp0;
cmp0 = cmp1;
cmp1 = temp;
break;
{
rtx temp;
code = swap_condition (code);
temp = cmp0;
cmp0 = cmp1;
cmp1 = temp;
break;
}
default:
break;
}
if (branch_p)
{
rtx insn;
rtx insn, cond, label;
/* Operands must be in registers. */
if (!register_operand (cmp0, mode))
......@@ -211,8 +215,8 @@ gen_int_relational (enum rtx_code code,
cmp1 = force_reg (mode, cmp1);
/* Generate conditional branch instruction. */
rtx cond = gen_rtx_fmt_ee (code, mode, cmp0, cmp1);
rtx label = gen_rtx_LABEL_REF (VOIDmode, destination);
cond = gen_rtx_fmt_ee (code, mode, cmp0, cmp1);
label = gen_rtx_LABEL_REF (VOIDmode, destination);
insn = gen_rtx_SET (VOIDmode, pc_rtx,
gen_rtx_IF_THEN_ELSE (VOIDmode,
cond, label, pc_rtx));
......@@ -841,7 +845,7 @@ lm32_block_move_inline (rtx dest, rtx src, HOST_WIDE_INT length,
delta = bits / BITS_PER_UNIT;
/* Allocate a buffer for the temporary registers. */
regs = alloca (sizeof (rtx) * length / delta);
regs = XALLOCAVEC (rtx, length / delta);
/* Load as many BITS-sized chunks as possible. */
for (offset = 0, i = 0; offset + delta <= length; offset += delta, i++)
......
......@@ -350,7 +350,7 @@ enum reg_class
#define REG_OK_FOR_BASE_P(X) NONSTRICT_REG_OK_FOR_BASE_P(X)
#endif
#define LEGITIMATE_CONSTANT_P(X) lm32_legitimate_constant_p
#define LEGITIMATE_CONSTANT_P(X) lm32_legitimate_constant_p (X)
/*-------------------------*/
/* Condition Code Status. */
......
......@@ -824,7 +824,6 @@
{
int i;
int shifts = INTVAL (operands[2]);
rtx one = GEN_INT (1);
if (shifts == 0)
emit_move_insn (operands[0], operands[1]);
......
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