mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-06 09:13:55 -06:00
target/arm: Implement the IRG instruction
Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Richard Henderson <richard.henderson@linaro.org> Message-id: 20200626033144.790098-10-richard.henderson@linaro.org Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
This commit is contained in:
parent
81ae05fa2d
commit
da54941f45
5 changed files with 98 additions and 0 deletions
|
@ -226,6 +226,12 @@ static TCGv_i64 clean_data_tbi(DisasContext *s, TCGv_i64 addr)
|
|||
return clean;
|
||||
}
|
||||
|
||||
/* Insert a zero tag into src, with the result at dst. */
|
||||
static void gen_address_with_allocation_tag0(TCGv_i64 dst, TCGv_i64 src)
|
||||
{
|
||||
tcg_gen_andi_i64(dst, src, ~MAKE_64BIT_MASK(56, 4));
|
||||
}
|
||||
|
||||
typedef struct DisasCompare64 {
|
||||
TCGCond cond;
|
||||
TCGv_i64 value;
|
||||
|
@ -5284,6 +5290,18 @@ static void disas_data_proc_2src(DisasContext *s, uint32_t insn)
|
|||
case 3: /* SDIV */
|
||||
handle_div(s, true, sf, rm, rn, rd);
|
||||
break;
|
||||
case 4: /* IRG */
|
||||
if (sf == 0 || !dc_isar_feature(aa64_mte_insn_reg, s)) {
|
||||
goto do_unallocated;
|
||||
}
|
||||
if (s->ata) {
|
||||
gen_helper_irg(cpu_reg_sp(s, rd), cpu_env,
|
||||
cpu_reg_sp(s, rn), cpu_reg(s, rm));
|
||||
} else {
|
||||
gen_address_with_allocation_tag0(cpu_reg_sp(s, rd),
|
||||
cpu_reg_sp(s, rn));
|
||||
}
|
||||
break;
|
||||
case 8: /* LSLV */
|
||||
handle_shift_reg(s, A64_SHIFT_TYPE_LSL, sf, rm, rn, rd);
|
||||
break;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue