diff options
| author | Peter Maydell | 2013-06-02 17:17:49 +0200 |
|---|---|---|
| committer | Anthony Liguori | 2013-06-10 18:36:12 +0200 |
| commit | 4039736e6f7867a4f937145afec7ab56531c0be4 (patch) | |
| tree | 402baeeae294b8a8c2114fa71f2d35a5b31622d2 /fpu | |
| parent | gdbstub: let the debugger resume from guest panicked state (diff) | |
| download | qemu-4039736e6f7867a4f937145afec7ab56531c0be4.tar.gz qemu-4039736e6f7867a4f937145afec7ab56531c0be4.tar.xz qemu-4039736e6f7867a4f937145afec7ab56531c0be4.zip | |
softfloat: Fix shift128Right for shift counts 64..127
shift128Right would give the wrong result for a shift count
between 64 and 127. This was never noticed because all of
our uses of this function are guaranteed not to use shift
counts in this range.
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>
Message-id: 1370186269-24353-1-git-send-email-peter.maydell@linaro.org
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Diffstat (limited to 'fpu')
| -rw-r--r-- | fpu/softfloat-macros.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fpu/softfloat-macros.h b/fpu/softfloat-macros.h index b5164af7fa..9b095456c5 100644 --- a/fpu/softfloat-macros.h +++ b/fpu/softfloat-macros.h @@ -168,7 +168,7 @@ INLINE void z0 = a0>>count; } else { - z1 = ( count < 64 ) ? ( a0>>( count & 63 ) ) : 0; + z1 = (count < 128) ? (a0 >> (count & 63)) : 0; z0 = 0; } *z1Ptr = z1; |
