[llvm] [InstSimplify] Defer to ConstantFold in simplifyInstrinsic (PR #205061)

Antonio Frighetto via llvm-commits llvm-commits at lists.llvm.org
Wed Jun 24 07:37:09 PDT 2026


================
@@ -7504,7 +7511,8 @@ static Value *simplifyIntrinsic(CallBase *Call, ArrayRef<Value *> Args,
   }
   default: {
     // Use the default FP environment if none is found.
-    fp::ExceptionBehavior ExBehavior = fp::ebIgnore;
+    fp::ExceptionBehavior ExBehavior =
+        Call->isStrictFP() ? fp::ebStrict : fp::ebIgnore;
----------------
antoniofrighetto wrote:

> yes, it is tested with this PR.

Sorry, I might be missing something, though I don't see any strictfp call site in tests. Did you mean that this fix is necessary after the ConstantFoldIntrinsic() addition, in order to make existing tests pass?


https://github.com/llvm/llvm-project/pull/205061


More information about the llvm-commits mailing list