[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v2 16/71] target/arm: Use expand_pred_b in mve_helper.c
From: |
Richard Henderson |
Subject: |
[PATCH v2 16/71] target/arm: Use expand_pred_b in mve_helper.c |
Date: |
Tue, 7 Jun 2022 13:32:11 -0700 |
Use the function instead of the array directly.
Because the function performs its own masking, via the uint8_t
parameter, we need to do nothing extra within the users: the bits
above the first 2 (_uh) or 4 (_uw) will be discarded by assignment
to the local bmask variables, and of course _uq uses the entire
uint64_t result.
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
---
target/arm/mve_helper.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/target/arm/mve_helper.c b/target/arm/mve_helper.c
index 846962bf4c..403b345ea3 100644
--- a/target/arm/mve_helper.c
+++ b/target/arm/mve_helper.c
@@ -726,7 +726,7 @@ static void mergemask_sb(int8_t *d, int8_t r, uint16_t mask)
static void mergemask_uh(uint16_t *d, uint16_t r, uint16_t mask)
{
- uint16_t bmask = expand_pred_b_data[mask & 3];
+ uint16_t bmask = expand_pred_b(mask);
*d = (*d & ~bmask) | (r & bmask);
}
@@ -737,7 +737,7 @@ static void mergemask_sh(int16_t *d, int16_t r, uint16_t
mask)
static void mergemask_uw(uint32_t *d, uint32_t r, uint16_t mask)
{
- uint32_t bmask = expand_pred_b_data[mask & 0xf];
+ uint32_t bmask = expand_pred_b(mask);
*d = (*d & ~bmask) | (r & bmask);
}
@@ -748,7 +748,7 @@ static void mergemask_sw(int32_t *d, int32_t r, uint16_t
mask)
static void mergemask_uq(uint64_t *d, uint64_t r, uint16_t mask)
{
- uint64_t bmask = expand_pred_b_data[mask & 0xff];
+ uint64_t bmask = expand_pred_b(mask);
*d = (*d & ~bmask) | (r & bmask);
}
--
2.34.1
- [PATCH v2 11/71] target/arm: Use uint32_t instead of bitmap for sve vq's, (continued)
- [PATCH v2 11/71] target/arm: Use uint32_t instead of bitmap for sve vq's, Richard Henderson, 2022/06/07
- [PATCH v2 10/71] target/arm: Merge aarch64_sve_zcr_get_valid_len into caller, Richard Henderson, 2022/06/07
- [PATCH v2 13/71] target/arm: Split out load/store primitives to sve_ldst_internal.h, Richard Henderson, 2022/06/07
- [PATCH v2 17/71] target/arm: Move expand_pred_h to vec_internal.h, Richard Henderson, 2022/06/07
- [PATCH v2 18/71] target/arm: Export bfdotadd from vec_helper.c, Richard Henderson, 2022/06/07
- [PATCH v2 19/71] target/arm: Add isar_feature_aa64_sme, Richard Henderson, 2022/06/07
- [PATCH v2 15/71] target/arm: Move expand_pred_b to vec_internal.h, Richard Henderson, 2022/06/07
- [PATCH v2 26/71] target/arm: Add SMCR_ELx, Richard Henderson, 2022/06/07
- [PATCH v2 12/71] target/arm: Rename sve_zcr_len_for_el to sve_vqm1_for_el, Richard Henderson, 2022/06/07
- [PATCH v2 14/71] target/arm: Export sve contiguous ldst support functions, Richard Henderson, 2022/06/07
- [PATCH v2 16/71] target/arm: Use expand_pred_b in mve_helper.c,
Richard Henderson <=
- [PATCH v2 21/71] target/arm: Implement TPIDR2_EL0, Richard Henderson, 2022/06/07
- [PATCH v2 22/71] target/arm: Add SMEEXC_EL to TB flags, Richard Henderson, 2022/06/07
- [PATCH v2 23/71] target/arm: Add syn_smetrap, Richard Henderson, 2022/06/07
- [PATCH v2 24/71] target/arm: Add ARM_CP_SME, Richard Henderson, 2022/06/07
- [PATCH v2 25/71] target/arm: Add SVCR, Richard Henderson, 2022/06/07
- [PATCH v2 27/71] target/arm: Add SMIDR_EL1, SMPRI_EL1, SMPRIMAP_EL2, Richard Henderson, 2022/06/07
- [PATCH v2 28/71] target/arm: Add PSTATE.{SM,ZA} to TB flags, Richard Henderson, 2022/06/07
- [PATCH v2 29/71] target/arm: Add the SME ZA storage to CPUARMState, Richard Henderson, 2022/06/07