aboutsummaryrefslogtreecommitdiff
path: root/target/ppc
diff options
context:
space:
mode:
authorAnton Blanchard <anton@ozlabs.org>2019-05-09 06:17:33 +1000
committerDavid Gibson <david@gibson.dropbear.id.au>2019-05-29 11:39:44 +1000
commit4c406ca7345e874f16110734907af970c968d727 (patch)
tree6224d90ac53250c32945a25fc7da608d63e4ade2 /target/ppc
parent7fa0ddc1d63806769d1b6246a62708d3bde39037 (diff)
downloadqemu-4c406ca7345e874f16110734907af970c968d727.zip
qemu-4c406ca7345e874f16110734907af970c968d727.tar.gz
qemu-4c406ca7345e874f16110734907af970c968d727.tar.bz2
target/ppc: Fix xxspltib
xxspltib raises a VMX or a VSX exception depending on the register set it is operating on. We had a check, but it was backwards. Fixes: f113283525a4 ("target-ppc: add xxspltib instruction") Signed-off-by: Anton Blanchard <anton@ozlabs.org> Message-Id: <20190509061713.69490488@kryten> Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Diffstat (limited to 'target/ppc')
-rw-r--r--target/ppc/translate/vsx-impl.inc.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/target/ppc/translate/vsx-impl.inc.c b/target/ppc/translate/vsx-impl.inc.c
index d29f60e..4b8f6ce 100644
--- a/target/ppc/translate/vsx-impl.inc.c
+++ b/target/ppc/translate/vsx-impl.inc.c
@@ -1355,13 +1355,13 @@ static void gen_xxspltib(DisasContext *ctx)
int rt = xT(ctx->opcode);
if (rt < 32) {
- if (unlikely(!ctx->altivec_enabled)) {
- gen_exception(ctx, POWERPC_EXCP_VPU);
+ if (unlikely(!ctx->vsx_enabled)) {
+ gen_exception(ctx, POWERPC_EXCP_VSXU);
return;
}
} else {
- if (unlikely(!ctx->vsx_enabled)) {
- gen_exception(ctx, POWERPC_EXCP_VSXU);
+ if (unlikely(!ctx->altivec_enabled)) {
+ gen_exception(ctx, POWERPC_EXCP_VPU);
return;
}
}