mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-03 15:53:54 -06:00
target/arm: Pass pointer to qc to qrdmla/qrdmls
Pass a pointer directly to env->vfp.qc[0], rather than env. This will allow SVE2, which does not modify QC, to pass a pointer to dummy storage. Change the return type of inl_qrdml.h_s16 to match the sense of the operation: signed. Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Richard Henderson <richard.henderson@linaro.org> Message-id: 20200513163245.17915-14-richard.henderson@linaro.org Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
This commit is contained in:
parent
146aa66ce5
commit
e286bf4a72
2 changed files with 54 additions and 34 deletions
|
@ -3629,6 +3629,18 @@ static const uint8_t neon_2rm_sizes[] = {
|
|||
[NEON_2RM_VCVT_UF] = 0x4,
|
||||
};
|
||||
|
||||
static void gen_gvec_fn3_qc(uint32_t rd_ofs, uint32_t rn_ofs, uint32_t rm_ofs,
|
||||
uint32_t opr_sz, uint32_t max_sz,
|
||||
gen_helper_gvec_3_ptr *fn)
|
||||
{
|
||||
TCGv_ptr qc_ptr = tcg_temp_new_ptr();
|
||||
|
||||
tcg_gen_addi_ptr(qc_ptr, cpu_env, offsetof(CPUARMState, vfp.qc));
|
||||
tcg_gen_gvec_3_ptr(rd_ofs, rn_ofs, rm_ofs, qc_ptr,
|
||||
opr_sz, max_sz, 0, fn);
|
||||
tcg_temp_free_ptr(qc_ptr);
|
||||
}
|
||||
|
||||
void gen_gvec_sqrdmlah_qc(unsigned vece, uint32_t rd_ofs, uint32_t rn_ofs,
|
||||
uint32_t rm_ofs, uint32_t opr_sz, uint32_t max_sz)
|
||||
{
|
||||
|
@ -3636,8 +3648,7 @@ void gen_gvec_sqrdmlah_qc(unsigned vece, uint32_t rd_ofs, uint32_t rn_ofs,
|
|||
gen_helper_gvec_qrdmlah_s16, gen_helper_gvec_qrdmlah_s32
|
||||
};
|
||||
tcg_debug_assert(vece >= 1 && vece <= 2);
|
||||
tcg_gen_gvec_3_ptr(rd_ofs, rn_ofs, rm_ofs, cpu_env,
|
||||
opr_sz, max_sz, 0, fns[vece - 1]);
|
||||
gen_gvec_fn3_qc(rd_ofs, rn_ofs, rm_ofs, opr_sz, max_sz, fns[vece - 1]);
|
||||
}
|
||||
|
||||
void gen_gvec_sqrdmlsh_qc(unsigned vece, uint32_t rd_ofs, uint32_t rn_ofs,
|
||||
|
@ -3647,8 +3658,7 @@ void gen_gvec_sqrdmlsh_qc(unsigned vece, uint32_t rd_ofs, uint32_t rn_ofs,
|
|||
gen_helper_gvec_qrdmlsh_s16, gen_helper_gvec_qrdmlsh_s32
|
||||
};
|
||||
tcg_debug_assert(vece >= 1 && vece <= 2);
|
||||
tcg_gen_gvec_3_ptr(rd_ofs, rn_ofs, rm_ofs, cpu_env,
|
||||
opr_sz, max_sz, 0, fns[vece - 1]);
|
||||
gen_gvec_fn3_qc(rd_ofs, rn_ofs, rm_ofs, opr_sz, max_sz, fns[vece - 1]);
|
||||
}
|
||||
|
||||
#define GEN_CMP0(NAME, COND) \
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue