re PR target/54089 ([SH] Refactor shift patterns)

PR target/54089
	* config/sh/sh.md (ashlsi3_d): Invoke gen_shifty_op directly instead
	of trying to emit ashlsi3_n.

From-SVN: r189952
This commit is contained in:
Oleg Endo 2012-07-30 06:43:20 +00:00
parent c0fd34971d
commit be82afe609
2 changed files with 12 additions and 1 deletions

View file

@ -1,3 +1,9 @@
2012-07-30 Oleg Endo <olegendo@gcc.gnu.org>
PR target/54089
* config/sh/sh.md (ashlsi3_d): Invoke gen_shifty_op directly instead
of trying to emit ashlsi3_n.
2012-07-30 Laurynas Biveinis <laurynas.biveinis@gmail.com>
Steven Bosscher <steven@gcc.gnu.org>

View file

@ -3533,7 +3533,12 @@ label:
}
else if (!satisfies_constraint_P27 (operands[2]))
{
emit_insn (gen_ashlsi3_n (operands[0], operands[1], operands[2]));
/* This must happen before reload, otherwise the constant will be moved
into a register due to the "r" constraint, after which this split
cannot be done anymore.
Unfortunately the move insn will not always be eliminated. */
emit_move_insn (operands[0], operands[1]);
gen_shifty_op (ASHIFT, operands);
DONE;
}