aboutsummaryrefslogtreecommitdiff
path: root/target/arm/translate.c
diff options
context:
space:
mode:
authorRichard Henderson <richard.henderson@linaro.org>2020-11-02 16:52:13 +0000
committerPeter Maydell <peter.maydell@linaro.org>2020-11-02 16:52:13 +0000
commit0f2cdc82276a723ee58562b56b9d537a4bd7bfef (patch)
treec0bc2fa2275aa132a10b902d0209a5e03d642cfd /target/arm/translate.c
parent7ec85c02833f4264840c6ed78b749443a7b4ffe0 (diff)
target/arm: Use neon_element_offset in neon_load/store_reg
These are the only users of neon_reg_offset, so remove that. Signed-off-by: Richard Henderson <richard.henderson@linaro.org> Message-id: 20201030022618.785675-4-richard.henderson@linaro.org Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'target/arm/translate.c')
-rw-r--r--target/arm/translate.c14
1 files changed, 2 insertions, 12 deletions
diff --git a/target/arm/translate.c b/target/arm/translate.c
index bf0b5cac61..88a926d1df 100644
--- a/target/arm/translate.c
+++ b/target/arm/translate.c
@@ -1137,26 +1137,16 @@ static inline long vfp_reg_offset(bool dp, unsigned reg)
}
}
-/* Return the offset of a 32-bit piece of a NEON register.
- zero is the least significant end of the register. */
-static inline long
-neon_reg_offset (int reg, int n)
-{
- int sreg;
- sreg = reg * 2 + n;
- return vfp_reg_offset(0, sreg);
-}
-
static TCGv_i32 neon_load_reg(int reg, int pass)
{
TCGv_i32 tmp = tcg_temp_new_i32();
- tcg_gen_ld_i32(tmp, cpu_env, neon_reg_offset(reg, pass));
+ tcg_gen_ld_i32(tmp, cpu_env, neon_element_offset(reg, pass, MO_32));
return tmp;
}
static void neon_store_reg(int reg, int pass, TCGv_i32 var)
{
- tcg_gen_st_i32(var, cpu_env, neon_reg_offset(reg, pass));
+ tcg_gen_st_i32(var, cpu_env, neon_element_offset(reg, pass, MO_32));
tcg_temp_free_i32(var);
}