]> xenbits.xensource.com Git - qemu-upstream-4.6-testing.git/commitdiff
target-i386: fix movntsd on big-endian hosts
authorPaolo Bonzini <pbonzini@redhat.com>
Wed, 7 Jan 2015 16:36:27 +0000 (17:36 +0100)
committerMichael Roth <mdroth@linux.vnet.ibm.com>
Mon, 23 Feb 2015 00:15:01 +0000 (18:15 -0600)
This was accessing an XMM register's low half without going through XMM_Q.

Cc: qemu-stable@nongnu.org
Reviewed-by: Eduardo Habkost <ehabkost@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
(cherry picked from commit 07958082fdf39284935d38a5b8aec1fe7d020637)
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
target-i386/translate.c

index 782f7d266663d5dd8d99bff00540829bbfe17d37..269b88561e64f168f7bc6729a703b3bbf6149f1c 100644 (file)
@@ -3069,7 +3069,8 @@ static void gen_sse(CPUX86State *env, DisasContext *s, int b,
                 goto illegal_op;
             gen_lea_modrm(env, s, modrm);
             if (b1 & 1) {
-                gen_stq_env_A0(s, offsetof(CPUX86State, xmm_regs[reg]));
+                gen_stq_env_A0(s, offsetof(CPUX86State,
+                                           xmm_regs[reg].XMM_Q(0)));
             } else {
                 tcg_gen_ld32u_tl(cpu_T[0], cpu_env, offsetof(CPUX86State,
                     xmm_regs[reg].XMM_L(0)));