target/riscv: Convert RV64I load/store insns to decodetree

this splits the 64-bit only instructions into its own decode file such
that we generate the decoder for these instructions only for the RISC-V
64 bit target.

Acked-by: Alistair Francis <alistair.francis@wdc.com>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Bastian Koppelmann <kbastian@mail.uni-paderborn.de>
Signed-off-by: Peer Adelt <peer.adelt@hni.uni-paderborn.de>
This commit is contained in:
Bastian Koppelmann 2019-02-13 07:53:44 -08:00
parent c1000d4e1b
commit 7e45a682ed
4 changed files with 50 additions and 10 deletions

View file

@ -130,3 +130,23 @@ static bool trans_sw(DisasContext *ctx, arg_sw *a)
gen_store(ctx, OPC_RISC_SW, a->rs1, a->rs2, a->imm);
return true;
}
#ifdef TARGET_RISCV64
static bool trans_lwu(DisasContext *ctx, arg_lwu *a)
{
gen_load(ctx, OPC_RISC_LWU, a->rd, a->rs1, a->imm);
return true;
}
static bool trans_ld(DisasContext *ctx, arg_ld *a)
{
gen_load(ctx, OPC_RISC_LD, a->rd, a->rs1, a->imm);
return true;
}
static bool trans_sd(DisasContext *ctx, arg_sd *a)
{
gen_store(ctx, OPC_RISC_SD, a->rs1, a->rs2, a->imm);
return true;
}
#endif