This is an archive of the discontinued LLVM Phabricator instance.

Move three folds for FADD, FSUB and FMUL in the DAG combiner away from Unsafe to more aligned checks that reflect context
ClosedPublic

Authored by mcberg2017 on Jul 9 2019, 2:43 PM.

Details

Summary

Unsafe does not map well alone for each of these three cases as it is missing NoNan context when accessed directly with clang. I have migrated the fold guards to reflect the expectations of handing nan and zero contexts directly (NoNan, NSZ) and some tests with it. Unsafe does include NSZ, however there is already precedent for using the target option directly to reflect that context.

Diff Detail

Event Timeline

mcberg2017 created this revision.Jul 9 2019, 2:43 PM
arsenm accepted this revision.Jul 9 2019, 2:45 PM

LGTM

This revision is now accepted and ready to land.Jul 9 2019, 2:45 PM
This revision was automatically updated to reflect the committed changes.
Herald added a project: Restricted Project. · View Herald TranscriptJul 10 2019, 11:23 AM

For future reference, this patch omitted llvm-commits list, looks like phabricator still
sometimes doesn't automatically does the right thing, so one needs to manually ensure that.

lib/CodeGen/SelectionDAG/DAGCombiner.cpp