summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAvi Kivity <avi@redhat.com>2010-05-09 14:05:19 +0300
committerAvi Kivity <avi@redhat.com>2010-05-09 14:05:19 +0300
commit4b1b0617b6f454b368a7f04786c0bc842253f849 (patch)
tree46842c3026a59c6431e9c236734666b5d7286836 /target-i386
parentpci passthrough: zap option rom scanning. (diff)
parentUpdate for 0.12.4 release (diff)
downloadqemu-kvm-4b1b0617b6f454b368a7f04786c0bc842253f849.tar.gz
qemu-kvm-4b1b0617b6f454b368a7f04786c0bc842253f849.tar.bz2
qemu-kvm-4b1b0617b6f454b368a7f04786c0bc842253f849.zip
Merge commit 'v0.12.4' into stable-0.12qemu-kvm-0.12.4
* commit 'v0.12.4': (49 commits) Update for 0.12.4 release Workaround for broken OSS_GETVERSION on FreeBSD, part two oss: fix fragment setting oss: issue OSS_GETVERSION ioctl only when needed oss: refactor code around policy setting oss: workaround for cases when OSS_GETVERSION is not defined block: Free iovec arrays allocated by multiwrite_merge() lsi: fix segfault in lsi_command_complete lsi: pass lsi_request to lsi_reselect lsi: move dma_len+dma_buf into lsi_request lsi: move current_dev into lsi_request lsi: have lsi_request for the whole life time of the request. lsi: use QTAILQ for lsi_queue tcp/mips: Change TCG_AREG0 (fp -> s0) sh_pci: fix memory and I/O access Fix incoming migration with iothread Fix SIGFPE for vnc display of width/height = 1 net: remove broken net_set_boot_mask() boot device validation qcow2: Remove request from in-flight list after error qcow2: Don't ignore immediate read/write failures ... Signed-off-by: Avi Kivity <avi@redhat.com>
Diffstat (limited to 'target-i386')
-rw-r--r--target-i386/translate.c15
1 files changed, 9 insertions, 6 deletions
diff --git a/target-i386/translate.c b/target-i386/translate.c
index 511a4eae9..3de65bd1d 100644
--- a/target-i386/translate.c
+++ b/target-i386/translate.c
@@ -2047,8 +2047,8 @@ static void gen_lea_modrm(DisasContext *s, int modrm, int *reg_ptr, int *offset_
gen_op_movl_A0_im(disp);
}
}
- /* XXX: index == 4 is always invalid */
- if (havesib && (index != 4 || scale != 0)) {
+ /* index == 4 means no index */
+ if (havesib && (index != 4)) {
#ifdef TARGET_X86_64
if (s->aflag == 2) {
gen_op_addq_A0_reg_sN(scale, index);
@@ -3165,12 +3165,17 @@ static void gen_sse(DisasContext *s, int b, target_ulong pc_start, int rex_r)
case 0x1e7: /* movntdq */
case 0x02b: /* movntps */
case 0x12b: /* movntps */
- case 0x3f0: /* lddqu */
if (mod == 3)
goto illegal_op;
gen_lea_modrm(s, modrm, &reg_addr, &offset_addr);
gen_sto_env_A0(s->mem_index, offsetof(CPUX86State,xmm_regs[reg]));
break;
+ case 0x3f0: /* lddqu */
+ if (mod == 3)
+ goto illegal_op;
+ gen_lea_modrm(s, modrm, &reg_addr, &offset_addr);
+ gen_ldo_env_A0(s->mem_index, offsetof(CPUX86State,xmm_regs[reg]));
+ break;
case 0x22b: /* movntss */
case 0x32b: /* movntsd */
if (mod == 3)
@@ -4591,9 +4596,7 @@ static target_ulong disas_insn(DisasContext *s, target_ulong pc_start)
/* operand size for jumps is 64 bit */
ot = OT_QUAD;
} else if (op == 3 || op == 5) {
- /* for call calls, the operand is 16 or 32 bit, even
- in long mode */
- ot = dflag ? OT_LONG : OT_WORD;
+ ot = dflag ? OT_LONG + (rex_w == 1) : OT_WORD;
} else if (op == 6) {
/* default push size is 64 bit */
ot = dflag ? OT_QUAD : OT_WORD;