aboutsummaryrefslogtreecommitdiff
path: root/target/riscv/insn_trans
diff options
context:
space:
mode:
authorRichard Henderson <richard.henderson@linaro.org>2021-08-23 12:55:12 -0700
committerAlistair Francis <alistair.francis@wdc.com>2021-09-01 11:59:12 +1000
commitafbbec820149299943976ef8b957a37073f3a0b5 (patch)
tree9b28a0ae599a289a03ad07d78f74f7d3f049c614 /target/riscv/insn_trans
parent191d1dafae9cd502ef2d771f9e35c221815fe7ba (diff)
downloadqemu-afbbec820149299943976ef8b957a37073f3a0b5.zip
qemu-afbbec820149299943976ef8b957a37073f3a0b5.tar.gz
qemu-afbbec820149299943976ef8b957a37073f3a0b5.tar.bz2
target/riscv: Remove gen_arith_div*
Use ctx->w and the enhanced gen_arith function. Reviewed-by: Bin Meng <bmeng.cn@gmail.com> Reviewed-by: Alistair Francis <alistair.francis@wdc.com> Signed-off-by: Richard Henderson <richard.henderson@linaro.org> Message-id: 20210823195529.560295-8-richard.henderson@linaro.org Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
Diffstat (limited to 'target/riscv/insn_trans')
-rw-r--r--target/riscv/insn_trans/trans_rvm.c.inc16
1 files changed, 8 insertions, 8 deletions
diff --git a/target/riscv/insn_trans/trans_rvm.c.inc b/target/riscv/insn_trans/trans_rvm.c.inc
index 013b3f7..3d93b24 100644
--- a/target/riscv/insn_trans/trans_rvm.c.inc
+++ b/target/riscv/insn_trans/trans_rvm.c.inc
@@ -99,30 +99,30 @@ static bool trans_divw(DisasContext *ctx, arg_divw *a)
{
REQUIRE_64BIT(ctx);
REQUIRE_EXT(ctx, RVM);
-
- return gen_arith_div_w(ctx, a, &gen_div);
+ ctx->w = true;
+ return gen_arith(ctx, a, EXT_SIGN, gen_div);
}
static bool trans_divuw(DisasContext *ctx, arg_divuw *a)
{
REQUIRE_64BIT(ctx);
REQUIRE_EXT(ctx, RVM);
-
- return gen_arith_div_uw(ctx, a, &gen_divu);
+ ctx->w = true;
+ return gen_arith(ctx, a, EXT_ZERO, gen_divu);
}
static bool trans_remw(DisasContext *ctx, arg_remw *a)
{
REQUIRE_64BIT(ctx);
REQUIRE_EXT(ctx, RVM);
-
- return gen_arith_div_w(ctx, a, &gen_rem);
+ ctx->w = true;
+ return gen_arith(ctx, a, EXT_SIGN, gen_rem);
}
static bool trans_remuw(DisasContext *ctx, arg_remuw *a)
{
REQUIRE_64BIT(ctx);
REQUIRE_EXT(ctx, RVM);
-
- return gen_arith_div_uw(ctx, a, &gen_remu);
+ ctx->w = true;
+ return gen_arith(ctx, a, EXT_ZERO, gen_remu);
}