[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 33/47] target/arm: Use tcg_constant in CLRM, DLS, WLS, LE
From: |
Richard Henderson |
Subject: |
[PATCH 33/47] target/arm: Use tcg_constant in CLRM, DLS, WLS, LE |
Date: |
Tue, 26 Apr 2022 09:30:29 -0700 |
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
---
target/arm/translate.c | 16 +++++-----------
1 file changed, 5 insertions(+), 11 deletions(-)
diff --git a/target/arm/translate.c b/target/arm/translate.c
index e0469da0a1..0e9fde2589 100644
--- a/target/arm/translate.c
+++ b/target/arm/translate.c
@@ -8257,7 +8257,7 @@ static bool trans_CLRM(DisasContext *s, arg_CLRM *a)
s->eci_handled = true;
- zero = tcg_const_i32(0);
+ zero = tcg_constant_i32(0);
for (i = 0; i < 15; i++) {
if (extract32(a->list, i, 1)) {
/* Clear R[i] */
@@ -8269,11 +8269,8 @@ static bool trans_CLRM(DisasContext *s, arg_CLRM *a)
* Clear APSR (by calling the MSR helper with the same argument
* as for "MSR APSR_nzcvqg, Rn": mask = 0b1100, SYSM=0)
*/
- TCGv_i32 maskreg = tcg_const_i32(0xc << 8);
- gen_helper_v7m_msr(cpu_env, maskreg, zero);
- tcg_temp_free_i32(maskreg);
+ gen_helper_v7m_msr(cpu_env, tcg_constant_i32(0xc00), zero);
}
- tcg_temp_free_i32(zero);
clear_eci_state(s);
return true;
}
@@ -8416,8 +8413,7 @@ static bool trans_DLS(DisasContext *s, arg_DLS *a)
store_reg(s, 14, tmp);
if (a->size != 4) {
/* DLSTP: set FPSCR.LTPSIZE */
- tmp = tcg_const_i32(a->size);
- store_cpu_field(tmp, v7m.ltpsize);
+ store_cpu_field(tcg_constant_i32(a->size), v7m.ltpsize);
s->base.is_jmp = DISAS_UPDATE_NOCHAIN;
}
return true;
@@ -8482,8 +8478,7 @@ static bool trans_WLS(DisasContext *s, arg_WLS *a)
*/
bool ok = vfp_access_check(s);
assert(ok);
- tmp = tcg_const_i32(a->size);
- store_cpu_field(tmp, v7m.ltpsize);
+ store_cpu_field(tcg_constant_i32(a->size), v7m.ltpsize);
/*
* LTPSIZE updated, but MVE_NO_PRED will always be the same thing (0)
* when we take this upcoming exit from this TB, so gen_jmp_tb() is OK.
@@ -8609,8 +8604,7 @@ static bool trans_LE(DisasContext *s, arg_LE *a)
gen_set_label(loopend);
if (a->tp) {
/* Exits from tail-pred loops must reset LTPSIZE to 4 */
- tmp = tcg_const_i32(4);
- store_cpu_field(tmp, v7m.ltpsize);
+ store_cpu_field(tcg_constant_i32(4), v7m.ltpsize);
}
/* End TB, continuing to following insn */
gen_jmp_tb(s, s->base.pc_next, 1);
--
2.34.1
- [PATCH 23/47] target/arm: Use tcg_constant for disas_iwmmxt_insn, (continued)
- [PATCH 23/47] target/arm: Use tcg_constant for disas_iwmmxt_insn, Richard Henderson, 2022/04/26
- [PATCH 24/47] target/arm: Use tcg_constant for gen_{msr,mrs}, Richard Henderson, 2022/04/26
- [PATCH 27/47] target/arm: Use tcg_constant for gen_srs, Richard Henderson, 2022/04/26
- [PATCH 29/47] target/arm: Use tcg_constant for MOVW, UMAAL, CRC32, Richard Henderson, 2022/04/26
- [PATCH 34/47] target/arm: Use tcg_constant in trans_CPS_v7m, Richard Henderson, 2022/04/26
- [PATCH 33/47] target/arm: Use tcg_constant in CLRM, DLS, WLS, LE,
Richard Henderson <=
- [PATCH 22/47] target/arm: Use tcg_constant for aa32 exceptions, Richard Henderson, 2022/04/26
- [PATCH 25/47] target/arm: Use tcg_constant for vector shift expanders, Richard Henderson, 2022/04/26
- [PATCH 32/47] target/arm: Use tcg_constant in LDM, STM, Richard Henderson, 2022/04/26
- [PATCH 31/47] target/arm: Use tcg_constant for TT, SAT, SMMLA, Richard Henderson, 2022/04/26
- [PATCH 39/47] target/arm: Use tcg_constant in {incr, wrap}_last_active, Richard Henderson, 2022/04/26