mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-01-13 06:34:26 +08:00
* expr.c (move_block_from_reg): Try using an integral mov operation first.
From-SVN: r13897
This commit is contained in:
parent
ad5780142a
commit
58a32c5c03
14
gcc/expr.c
14
gcc/expr.c
@ -1717,9 +1717,21 @@ move_block_from_reg (regno, x, nregs, size)
|
||||
{
|
||||
int i;
|
||||
rtx pat, last;
|
||||
enum machine_mode mode;
|
||||
|
||||
/* If SIZE is that of a mode no bigger than a word, just use that
|
||||
mode's store operation. */
|
||||
if (size <= UNITS_PER_WORD
|
||||
&& (mode = mode_for_size (size * BITS_PER_UNIT, MODE_INT, 0)) != BLKmode)
|
||||
{
|
||||
emit_move_insn (change_address (x, mode, NULL),
|
||||
gen_rtx (REG, mode, regno));
|
||||
return;
|
||||
}
|
||||
|
||||
/* Blocks smaller than a word on a BYTES_BIG_ENDIAN machine must be aligned
|
||||
to the left before storing to memory. */
|
||||
to the left before storing to memory. Note that the previous test
|
||||
doesn't handle all cases (e.g. SIZE == 3). */
|
||||
if (size < UNITS_PER_WORD && BYTES_BIG_ENDIAN)
|
||||
{
|
||||
rtx tem = operand_subword (x, 0, 1, BLKmode);
|
||||
|
Loading…
Reference in New Issue
Block a user