[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 7/8] target-ppc: Bug Fix: srawi
From: |
Tom Musta |
Subject: |
[Qemu-devel] [PATCH 7/8] target-ppc: Bug Fix: srawi |
Date: |
Mon, 11 Aug 2014 14:23:28 -0500 |
For 64 bit implementations, the special case of a shift by zero
should result in the sign extension of the least significant 32 bits
of the source GPR (not a direct copy of the 64 bit source GPR).
Signed-off-by: Tom Musta <address@hidden>
---
target-ppc/translate.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/target-ppc/translate.c b/target-ppc/translate.c
index 4904665..61fa42d 100644
--- a/target-ppc/translate.c
+++ b/target-ppc/translate.c
@@ -1941,7 +1941,7 @@ static void gen_srawi(DisasContext *ctx)
TCGv dst = cpu_gpr[rA(ctx->opcode)];
TCGv src = cpu_gpr[rS(ctx->opcode)];
if (sh == 0) {
- tcg_gen_mov_tl(dst, src);
+ tcg_gen_ext32s_tl(dst, src);
tcg_gen_movi_tl(cpu_ca, 0);
} else {
TCGv t0;
--
1.7.1
- [Qemu-devel] [PATCH 2/8] target-ppc: Bug Fix: rlwnm, (continued)
- [Qemu-devel] [PATCH 2/8] target-ppc: Bug Fix: rlwnm, Tom Musta, 2014/08/11
- [Qemu-devel] [PATCH 3/8] target-ppc: Bug Fix: rlwimi, Tom Musta, 2014/08/11
- [Qemu-devel] [PATCH 4/8] target-ppc: Bug Fix: mullw, Tom Musta, 2014/08/11
- [Qemu-devel] [PATCH 5/8] target-ppc: Bug Fix: mullwo, Tom Musta, 2014/08/11
- [Qemu-devel] [PATCH 6/8] target-ppc: Bug Fix: mulldo OV Detection, Tom Musta, 2014/08/11
- [Qemu-devel] [PATCH 7/8] target-ppc: Bug Fix: srawi,
Tom Musta <=
- [Qemu-devel] [PATCH 8/8] target-ppc: Bug Fix: srad, Tom Musta, 2014/08/11
- Re: [Qemu-devel] [PATCH 0/8] target-ppc: Bug Fixes for 64 Bit FXU Instructions, David Gibson, 2014/08/11