qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [PATCH] target/mips: Fix minor bug in FPU


From: Mateja Marjanovic
Subject: [Qemu-devel] [PATCH] target/mips: Fix minor bug in FPU
Date: Thu, 7 Mar 2019 18:10:50 +0100

From: Mateja Marjanovic <address@hidden>

Wrong type of NaN was generated by maddf and msubf insturctions
when the arguments were inf, zero, nan or zero, inf, nan
respectively.

Signed-off-by: Mateja Marjanovic <address@hidden>
---
 fpu/softfloat-specialize.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/fpu/softfloat-specialize.h b/fpu/softfloat-specialize.h
index 16c0bcb..647bfbc 100644
--- a/fpu/softfloat-specialize.h
+++ b/fpu/softfloat-specialize.h
@@ -500,7 +500,7 @@ static int pickNaNMulAdd(FloatClass a_cls, FloatClass 
b_cls, FloatClass c_cls,
      */
     if (infzero) {
         float_raise(float_flag_invalid, status);
-        return 3;
+        return 2;
     }
 
     if (snan_bit_is_one(status)) {
-- 
2.7.4




reply via email to

[Prev in Thread] Current Thread [Next in Thread]