From fe44992b797fcbdf247abd860753feab22e6e148 Mon Sep 17 00:00:00 2001 From: Siva Chandra Reddy Date: Tue, 25 Aug 2020 23:32:55 -0700 Subject: [PATCH] [libc][NFC] For remquo quotient, compare only 3 bits of MPFR and libc results. --- libc/utils/MPFRWrapper/MPFRUtils.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libc/utils/MPFRWrapper/MPFRUtils.cpp b/libc/utils/MPFRWrapper/MPFRUtils.cpp index 1ee5cb1..a121234 100644 --- a/libc/utils/MPFRWrapper/MPFRUtils.cpp +++ b/libc/utils/MPFRWrapper/MPFRUtils.cpp @@ -448,7 +448,7 @@ bool compareBinaryOperationTwoOutputs(Operation op, const BinaryInput &input, if (mpfrIntResult != libcResult.i) { if (op == Operation::RemQuo) { - if ((0x7 & mpfrIntResult) != libcResult.i) + if ((0x7 & mpfrIntResult) != (0x7 & libcResult.i)) return false; } else { return false; -- 2.7.4