On 15/07/2015 14:55, Aurelien Jarno wrote:
> For a 64-bit host not implementing the trunc_shr_i32 op, the high bits
> of a register should be ignored for 32-bit ops. This is currently not
> the case of qemu_ld/st ops in user mode.
> 
> Fix that by either using the ADDR32 prefix (in case GUEST_BASE == 0 or
> a segment register is in use), or by doing an explicit zero-extension.
> The zero-extension can be done in place as we know the registers holds
> a 32-bit value.
> 
> Reported-by: Leon Alrae <leon.al...@imgtec.com>
> Cc: Leon Alrae <leon.al...@imgtec.com>
> Cc: Paolo Bonzini <pbonz...@redhat.com>
> Cc: Richard Henderson <r...@twiddle.net>
> Signed-off-by: Aurelien Jarno <aurel...@aurel32.net>
> ---
>  tcg/i386/tcg-target.c | 44 ++++++++++++++++++++++++++++++++------------
>  1 file changed, 32 insertions(+), 12 deletions(-)

Tested-by: Leon Alrae <leon.al...@imgtec.com>

Thanks for looking into this!

Leon


Reply via email to