fabs(x * x) is not generally safe to assume x is positive if x is a NaN.
This is also less general than it could be, so this will be replaced
with a transformation on the intrinsic.
Details
Details
Diff Detail
Diff Detail
Event Timeline
Comment Actions
You might want to put a comment in the tests briefly noting the problem with this transformation.
I think this transform is safe if the @llvm.fabs call is marked nnan, but I'm sure you already have some plan for that.
lib/Transforms/Utils/SimplifyLibCalls.cpp | ||
---|---|---|
1200 | Couldn't this stay if the fmul is marked as nnan? |
lib/Transforms/Utils/SimplifyLibCalls.cpp | ||
---|---|---|
1200 | Yes, but I want to move this to an optimization on the intrinsic |
Couldn't this stay if the fmul is marked as nnan?