target-i386: do not memcpy in and out of xmm_regs
authorPaolo Bonzini <pbonzini@redhat.com>
Fri, 24 Oct 2014 07:44:38 +0000 (09:44 +0200)
committerPaolo Bonzini <pbonzini@redhat.com>
Wed, 14 Jan 2015 09:38:57 +0000 (10:38 +0100)
commitbee818872cd9e8c07be529f75da3e48a68bf7a93
tree4b922dc78530784a8a38fec27e11970f73060592
parent07958082fdf39284935d38a5b8aec1fe7d020637
target-i386: do not memcpy in and out of xmm_regs

After the next patch, we will move the high parts of AVX and AVX512 registers
in the same array as the SSE registers.  This will make it impossible to
memcpy an array of 128-bit values in and out of xmm_regs in one swoop.
Use a for loop instead.

Similarly, always use XMM_Q in translate.c.  This avoids introducing bugs
such as the one fixed in the previous patch.

Reviewed-by: Eduardo Habkost <ehabkost@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
target-i386/kvm.c
target-i386/translate.c