summaryrefslogtreecommitdiffstats
path: root/tcg/ppc/tcg-target.h
diff options
context:
space:
mode:
authorMatheus Kowalczuk Ferst2022-06-13 16:43:59 +0200
committerRichard Henderson2022-06-20 21:56:28 +0200
commit4d5738222ff0a7f4d56fd4a2971b0605726a8fb2 (patch)
treee889671038555eceebcec17ebfd37d49f4b7d0a8 /tcg/ppc/tcg-target.h
parentMerge tag 'bsd-user-syscall-2022q2-pull-request' of ssh://github.com/qemu-bsd... (diff)
downloadqemu-4d5738222ff0a7f4d56fd4a2971b0605726a8fb2.tar.gz
qemu-4d5738222ff0a7f4d56fd4a2971b0605726a8fb2.tar.xz
qemu-4d5738222ff0a7f4d56fd4a2971b0605726a8fb2.zip
tcg/ppc: implement rem[u]_i{32,64} with mod[su][wd]
Power ISA v3.0 introduced mod[su][wd] insns that can be used to implement rem[u]_i{32,64}. Signed-off-by: Matheus Ferst <matheus.ferst@eldorado.org.br> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Diffstat (limited to 'tcg/ppc/tcg-target.h')
-rw-r--r--tcg/ppc/tcg-target.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/tcg/ppc/tcg-target.h b/tcg/ppc/tcg-target.h
index e6cf72503f..b5cd225cfa 100644
--- a/tcg/ppc/tcg-target.h
+++ b/tcg/ppc/tcg-target.h
@@ -83,7 +83,7 @@ extern bool have_vsx;
/* optional instructions */
#define TCG_TARGET_HAS_div_i32 1
-#define TCG_TARGET_HAS_rem_i32 0
+#define TCG_TARGET_HAS_rem_i32 have_isa_3_00
#define TCG_TARGET_HAS_rot_i32 1
#define TCG_TARGET_HAS_ext8s_i32 1
#define TCG_TARGET_HAS_ext16s_i32 1
@@ -117,7 +117,7 @@ extern bool have_vsx;
#define TCG_TARGET_HAS_extrl_i64_i32 0
#define TCG_TARGET_HAS_extrh_i64_i32 0
#define TCG_TARGET_HAS_div_i64 1
-#define TCG_TARGET_HAS_rem_i64 0
+#define TCG_TARGET_HAS_rem_i64 have_isa_3_00
#define TCG_TARGET_HAS_rot_i64 1
#define TCG_TARGET_HAS_ext8s_i64 1
#define TCG_TARGET_HAS_ext16s_i64 1