[clang] [llvm] [IR] Allow non-constrained math intrinsics in strictfp functions (PR #188297)

Serge Pavlov via cfe-commits cfe-commits at lists.llvm.org
Mon Mar 30 02:17:35 PDT 2026


spavloff wrote:

> However, there is a point in there: this patch defaults the intrinsics to being treated as NOT having side-effects, and then only adds the side-effect when you can see that they're inside a non-NULL function, with the strictfp attribute. That will give incorrect information if the property is ever queried when the instruction has not been added to a Function yet.
> 
> But the fix to that seems easy -- just do the opposite, and model them as always having a side-effect unless we see that it is in a function without strictfp.
>

 `CallBase::getFloatingPointMemoryEffects` has been changed accordingly.

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


More information about the cfe-commits mailing list