================
@@ -2800,7 +2800,8 @@ fn -> other_fn -> other_fn ; fn is norecurse
     optimizations that require assumptions about the floating-point rounding
     mode or that might alter the state of floating-point status flags that
     might otherwise be set or cleared by calling this function. LLVM will
-    not introduce any new floating-point instructions that may trap.
+    not introduce any new floating-point instructions that may trap. All
+    function definitions that contain strictfp calls must be marked strictfp.
----------------
cofibrant wrote:

I wasn't actually aware of such intrinsics, but there are two lines in the 
LangRef that will maybe offer some explanation:
> If any FP operation in a function is constrained then they all must be 
> constrained. This is required for correct LLVM IR.

> All function calls done in a function that uses constrained floating point 
> intrinsics must have the `strictfp` attribute either on the calling 
> instruction or on the declaration or definition of the function being called.

(Otherwise the callee might raise an FP exception which is incorrectly 
optimised).

I'll look at #205061 when I find some time

https://github.com/llvm/llvm-project/pull/211769
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to