From 8c1419fb8939cb5e0c260208c07b31b3c156b6c1 Mon Sep 17 00:00:00 2001 From: Joel Dice Date: Thu, 4 Apr 2013 20:02:49 -0600 Subject: [PATCH] jump to target if JumpIfFloatNotEqual comparison is unordered A dcmpl or dcmpg followed by an ifneq should take the branch if an NaN is involved. --- src/codegen/target/x86/encode.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/codegen/target/x86/encode.cpp b/src/codegen/target/x86/encode.cpp index e2f1ee287e..97c85d5fc3 100644 --- a/src/codegen/target/x86/encode.cpp +++ b/src/codegen/target/x86/encode.cpp @@ -251,6 +251,7 @@ void branchFloat(Context* c, lir::TernaryOperation op, lir::Constant* target) { case lir::JumpIfFloatNotEqual: conditional(c, 0x85, target); + conditional(c, 0x8a, target); break; case lir::JumpIfFloatLess: