[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 043/117] target/arm: Hoist sve access check through do_sel_z
From: |
Peter Maydell |
Subject: |
[PULL 043/117] target/arm: Hoist sve access check through do_sel_z |
Date: |
Mon, 30 May 2022 17:05:54 +0100 |
From: Richard Henderson <richard.henderson@linaro.org>
The check is already done in gen_gvec_ool_zzzp,
which is called by do_sel_z; remove from callers.
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-id: 20220527181907.189259-41-richard.henderson@linaro.org
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
---
target/arm/translate-sve.c | 14 ++++----------
1 file changed, 4 insertions(+), 10 deletions(-)
diff --git a/target/arm/translate-sve.c b/target/arm/translate-sve.c
index 6fa721eca62..62bfc6fe7c4 100644
--- a/target/arm/translate-sve.c
+++ b/target/arm/translate-sve.c
@@ -697,13 +697,13 @@ TRANS_FEAT(UQSUB_zzz, aa64_sve, gen_gvec_fn_arg_zzz,
tcg_gen_gvec_ussub, a)
/* Select active elememnts from Zn and inactive elements from Zm,
* storing the result in Zd.
*/
-static void do_sel_z(DisasContext *s, int rd, int rn, int rm, int pg, int esz)
+static bool do_sel_z(DisasContext *s, int rd, int rn, int rm, int pg, int esz)
{
static gen_helper_gvec_4 * const fns[4] = {
gen_helper_sve_sel_zpzz_b, gen_helper_sve_sel_zpzz_h,
gen_helper_sve_sel_zpzz_s, gen_helper_sve_sel_zpzz_d
};
- gen_gvec_ool_zzzp(s, fns[esz], rd, rn, rm, pg, 0);
+ return gen_gvec_ool_zzzp(s, fns[esz], rd, rn, rm, pg, 0);
}
#define DO_ZPZZ(NAME, FEAT, name) \
@@ -749,10 +749,7 @@ TRANS_FEAT(UDIV_zpzz, aa64_sve, gen_gvec_ool_arg_zpzz,
udiv_fns[a->esz], a, 0)
static bool trans_SEL_zpzz(DisasContext *s, arg_rprr_esz *a)
{
- if (sve_access_check(s)) {
- do_sel_z(s, a->rd, a->rn, a->rm, a->pg, a->esz);
- }
- return true;
+ return do_sel_z(s, a->rd, a->rn, a->rm, a->pg, a->esz);
}
/*
@@ -6343,10 +6340,7 @@ static bool trans_MOVPRFX(DisasContext *s, arg_MOVPRFX
*a)
static bool trans_MOVPRFX_m(DisasContext *s, arg_rpr_esz *a)
{
- if (sve_access_check(s)) {
- do_sel_z(s, a->rd, a->rn, a->rd, a->pg, a->esz);
- }
- return true;
+ return do_sel_z(s, a->rd, a->rn, a->rd, a->pg, a->esz);
}
static bool trans_MOVPRFX_z(DisasContext *s, arg_rpr_esz *a)
--
2.25.1
- [PULL 028/117] target/arm: Move null function and sve check into gen_gvec_ool_zzzp, (continued)
- [PULL 028/117] target/arm: Move null function and sve check into gen_gvec_ool_zzzp, Peter Maydell, 2022/05/30
- [PULL 041/117] target/arm: Introduce gen_gvec_fn_zzi, Peter Maydell, 2022/05/30
- [PULL 037/117] target/arm: Use TRANS_FEAT for do_sve2_fn_zzz, Peter Maydell, 2022/05/30
- [PULL 047/117] target/arm: Use TRANS_FEAT for do_shift_imm, Peter Maydell, 2022/05/30
- [PULL 053/117] target/arm: Use TRANS_FEAT for do_adr, Peter Maydell, 2022/05/30
- [PULL 055/117] target/arm: Use TRANS_FEAT for RDFFR, WRFFR, Peter Maydell, 2022/05/30
- [PULL 057/117] target/arm: Use TRANS_FEAT for do_EXT, Peter Maydell, 2022/05/30
- [PULL 038/117] target/arm: Use TRANS_FEAT for RAX1, Peter Maydell, 2022/05/30
- [PULL 044/117] target/arm: Introduce gen_gvec_fn_arg_zzi, Peter Maydell, 2022/05/30
- [PULL 048/117] target/arm: Introduce do_shift_zpzi, Peter Maydell, 2022/05/30
- [PULL 043/117] target/arm: Hoist sve access check through do_sel_z,
Peter Maydell <=
- [PULL 050/117] target/arm: Use TRANS_FEAT for do_zpzzz_ool, Peter Maydell, 2022/05/30
- [PULL 059/117] target/arm: Use TRANS_FEAT for do_perm_pred2, Peter Maydell, 2022/05/30
- [PULL 063/117] target/arm: Use TRANS_FEAT for do_clast_vector, Peter Maydell, 2022/05/30
- [PULL 083/117] target/arm: Implement NOT (prediates) alias, Peter Maydell, 2022/05/30
- [PULL 049/117] target/arm: Use TRANS_FEAT for do_shift_zpzi, Peter Maydell, 2022/05/30
- [PULL 042/117] target/arm: Use TRANS_FEAT for do_zz_dbm, Peter Maydell, 2022/05/30
- [PULL 045/117] target/arm: Use TRANS_FEAT for do_sve2_fn2i, Peter Maydell, 2022/05/30
- [PULL 054/117] target/arm: Use TRANS_FEAT for do_predset, Peter Maydell, 2022/05/30
- [PULL 056/117] target/arm: Use TRANS_FEAT for do_pfirst_pnext, Peter Maydell, 2022/05/30
- [PULL 068/117] target/arm: Use TRANS_FEAT for SPLICE, Peter Maydell, 2022/05/30