diff options
author | Denis Chertykov <denisc@overta.ru> | 2002-09-09 18:20:45 +0000 |
---|---|---|
committer | Denis Chertykov <denisc@gcc.gnu.org> | 2002-09-09 22:20:45 +0400 |
commit | a973864338539f4b1e9f27b517ea3c6caa1e3f8d (patch) | |
tree | 5d7957fdd48b7fe7c307d88c588f74cd367887c6 /gcc/config/avr | |
parent | 05b9aaaa89af451a049e106366a7827446518355 (diff) | |
download | gcc-a973864338539f4b1e9f27b517ea3c6caa1e3f8d.zip gcc-a973864338539f4b1e9f27b517ea3c6caa1e3f8d.tar.gz gcc-a973864338539f4b1e9f27b517ea3c6caa1e3f8d.tar.bz2 |
avr.md (movstrhi, clrstrhi): Use gen_int_mode for right conversion of operands[1].
* config/avr/avr.md (movstrhi, clrstrhi): Use gen_int_mode for
right conversion of operands[1].
From-SVN: r56975
Diffstat (limited to 'gcc/config/avr')
-rw-r--r-- | gcc/config/avr/avr.md | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/gcc/config/avr/avr.md b/gcc/config/avr/avr.md index a285fef..0c050b7 100644 --- a/gcc/config/avr/avr.md +++ b/gcc/config/avr/avr.md @@ -356,13 +356,14 @@ "{ rtx addr0, addr1; int cnt8; + enum machine_mode mode; if (GET_CODE (operands[2]) != CONST_INT) FAIL; - cnt8 = byte_immediate_operand (operands[2], GET_MODE (operands[2])); - operands[2] = copy_to_mode_reg (cnt8 ? QImode : HImode, operands[2]); - operands[4] = operands[2]; - + cnt8 = byte_immediate_operand (operands[1], GET_MODE (operands[1])); + mode = cnt8 ? QImode : HImode; + operands[1] = copy_to_mode_reg (mode, + gen_int_mode (INTVAL (operands[1]), mode)); addr0 = copy_to_mode_reg (Pmode, XEXP (operands[0], 0)); addr1 = copy_to_mode_reg (Pmode, XEXP (operands[1], 0)); @@ -428,12 +429,15 @@ "{ rtx addr0; int cnt8; + enum machine_mode mode; if (GET_CODE (operands[1]) != CONST_INT) FAIL; cnt8 = byte_immediate_operand (operands[1], GET_MODE (operands[1])); - operands[1] = copy_to_mode_reg (cnt8 ? QImode : HImode, operands[1]); + mode = cnt8 ? QImode : HImode; + operands[1] = copy_to_mode_reg (mode, + gen_int_mode (INTVAL (operands[1]), mode)); operands[3] = operands[1]; addr0 = copy_to_mode_reg (Pmode, XEXP (operands[0], 0)); |