Skip to content
Commit c8d91b07 authored by Sven van Haastregt's avatar Sven van Haastregt
Browse files

Reassoc FMF should not optimize FMA(a, 0, b) to (b)

Optimizing (a * 0 + b) to (b) requires assuming that a is finite and not
NaN. DAGCombiner will do this optimization when the reassoc fast math
flag is set, which is not correct. Change DAGCombiner to only consider
UnsafeMath for this optimization.

Differential Revision: https://reviews.llvm.org/D130232



Co-authored-by: default avatarAndrea Faulds <andrea.faulds@arm.com>
parent 1bc7b06f
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment