[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH] target-i386: Fix regression with maxsd SSE2 ins
From: |
Peter Maydell |
Subject: |
Re: [Qemu-devel] [PATCH] target-i386: Fix regression with maxsd SSE2 instruction |
Date: |
Tue, 8 Nov 2011 14:40:27 +0000 |
On 8 November 2011 14:22, Jason Wessel <address@hidden> wrote:
> +#define FPU_MIN(size, a, b) float ## size ## _lt(a, b, &env->sse_status) ?
> (a) : (b)
> +#define FPU_MAX(size, a, b) float ## size ## _lt(b, a, &env->sse_status) ?
> (a) : (b)
This will give the wrong answers for special cases involving +0, -0
and NaNs. Check the intel architecture manual which says how these
should work.
(You can't use float*_min() and float*_max() either, as those have
sane semantics and you need to implement the Intel ones here.)
-- PMM