mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-05 16:53:55 -06:00
target/riscv: rvv-1.0: count population in mask instruction
Signed-off-by: Frank Chang <frank.chang@sifive.com> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Reviewed-by: Alistair Francis <alistair.francis@wdc.com> Message-Id: <20211210075704.23951-30-frank.chang@sifive.com> Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
This commit is contained in:
parent
0676d8e3dc
commit
0014aa741d
4 changed files with 9 additions and 8 deletions
|
@ -2664,8 +2664,8 @@ GEN_MM_TRANS(vmnor_mm)
|
|||
GEN_MM_TRANS(vmornot_mm)
|
||||
GEN_MM_TRANS(vmxnor_mm)
|
||||
|
||||
/* Vector mask population count vmpopc */
|
||||
static bool trans_vmpopc_m(DisasContext *s, arg_rmr *a)
|
||||
/* Vector count population in mask vcpop */
|
||||
static bool trans_vcpop_m(DisasContext *s, arg_rmr *a)
|
||||
{
|
||||
if (require_rvv(s) &&
|
||||
vext_check_isa_ill(s)) {
|
||||
|
@ -2684,11 +2684,12 @@ static bool trans_vmpopc_m(DisasContext *s, arg_rmr *a)
|
|||
tcg_gen_addi_ptr(src2, cpu_env, vreg_ofs(s, a->rs2));
|
||||
tcg_gen_addi_ptr(mask, cpu_env, vreg_ofs(s, 0));
|
||||
|
||||
gen_helper_vmpopc_m(dst, mask, src2, cpu_env, desc);
|
||||
gen_helper_vcpop_m(dst, mask, src2, cpu_env, desc);
|
||||
gen_set_gpr(s, a->rd, dst);
|
||||
|
||||
tcg_temp_free_ptr(mask);
|
||||
tcg_temp_free_ptr(src2);
|
||||
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue