[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 12/54] target/arm: Use tcg_constant in disas_movw_imm
From: |
Peter Maydell |
Subject: |
[PULL 12/54] target/arm: Use tcg_constant in disas_movw_imm |
Date: |
Thu, 28 Apr 2022 15:39:16 +0100 |
From: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Message-id: 20220426163043.100432-13-richard.henderson@linaro.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
---
target/arm/translate-a64.c | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/target/arm/translate-a64.c b/target/arm/translate-a64.c
index 6c88772eb32..537eebbf1da 100644
--- a/target/arm/translate-a64.c
+++ b/target/arm/translate-a64.c
@@ -4419,7 +4419,6 @@ static void disas_movw_imm(DisasContext *s, uint32_t insn)
int opc = extract32(insn, 29, 2);
int pos = extract32(insn, 21, 2) << 4;
TCGv_i64 tcg_rd = cpu_reg(s, rd);
- TCGv_i64 tcg_imm;
if (!sf && (pos >= 32)) {
unallocated_encoding(s);
@@ -4439,9 +4438,7 @@ static void disas_movw_imm(DisasContext *s, uint32_t insn)
tcg_gen_movi_i64(tcg_rd, imm);
break;
case 3: /* MOVK */
- tcg_imm = tcg_const_i64(imm);
- tcg_gen_deposit_i64(tcg_rd, tcg_rd, tcg_imm, pos, 16);
- tcg_temp_free_i64(tcg_imm);
+ tcg_gen_deposit_i64(tcg_rd, tcg_rd, tcg_constant_i64(imm), pos, 16);
if (!sf) {
tcg_gen_ext32u_i64(tcg_rd, tcg_rd);
}
--
2.25.1
- [PULL 07/54] target/arm: Use tcg_constant in disas_exc, (continued)
- [PULL 07/54] target/arm: Use tcg_constant in disas_exc, Peter Maydell, 2022/04/28
- [PULL 15/54] target/arm: Use tcg_constant in handle_{rev16,crc32}, Peter Maydell, 2022/04/28
- [PULL 09/54] target/arm: Use tcg_constant in disas_ld_lit, Peter Maydell, 2022/04/28
- [PULL 11/54] target/arm: Use tcg_constant in disas_add_sum_imm*, Peter Maydell, 2022/04/28
- [PULL 13/54] target/arm: Use tcg_constant in shift_reg_imm, Peter Maydell, 2022/04/28
- [PULL 14/54] target/arm: Use tcg_constant in disas_cond_select, Peter Maydell, 2022/04/28
- [PULL 16/54] target/arm: Use tcg_constant in disas_data_proc_2src, Peter Maydell, 2022/04/28
- [PULL 03/54] target/arm: Use tcg_constant in gen_exception*, Peter Maydell, 2022/04/28
- [PULL 08/54] target/arm: Use tcg_constant in gen_compare_and_swap_pair, Peter Maydell, 2022/04/28
- [PULL 10/54] target/arm: Use tcg_constant in disas_ldst_*, Peter Maydell, 2022/04/28
- [PULL 12/54] target/arm: Use tcg_constant in disas_movw_imm,
Peter Maydell <=
- [PULL 18/54] target/arm: Use tcg_constant in simd shift expanders, Peter Maydell, 2022/04/28
- [PULL 19/54] target/arm: Use tcg_constant in simd fp/int conversion, Peter Maydell, 2022/04/28
- [PULL 20/54] target/arm: Use tcg_constant in 2misc expanders, Peter Maydell, 2022/04/28
- [PULL 23/54] target/arm: Use tcg_constant for disas_iwmmxt_insn, Peter Maydell, 2022/04/28
- [PULL 22/54] target/arm: Use tcg_constant for aa32 exceptions, Peter Maydell, 2022/04/28
- [PULL 29/54] target/arm: Use tcg_constant for MOVW, UMAAL, CRC32, Peter Maydell, 2022/04/28
- [PULL 17/54] target/arm: Use tcg_constant in disas_fp*, Peter Maydell, 2022/04/28
- [PULL 34/54] target/arm: Use tcg_constant in trans_CPS_v7m, Peter Maydell, 2022/04/28
- [PULL 35/54] target/arm: Use tcg_constant in trans_CSEL, Peter Maydell, 2022/04/28
- [PULL 41/54] target/arm: Use tcg_constant in WHILE, Peter Maydell, 2022/04/28