FailedChanges

Summary

  1. [InstCombine] Add extra tests for overflow_to_sat.ll. NFC (details)
  2. [InstCombine] Canonicalize sadd.with.overflow with clamp to sadd.sat (details)
  3. [InstCombine] Canonicalize ssub.with.overflow with clamp to ssub.sat (details)
  4. [SimplifyCFG] add tests for possible FP speculative select; NFC (details)
  5. [SimplifyCFG] add fast-math-flags to tests for better coverage; NFC (details)
  6. [SimplifyCFG] propagate fast-math-flags (FMF) from phi to select (details)
Commit 7bed2cb8535085cf041f6f5d0c65135a898c302e by david.green
[InstCombine] Add extra tests for overflow_to_sat.ll. NFC
The file was modifiedllvm/test/Transforms/InstCombine/overflow_to_sat.ll
Commit 03fce6b12e677144968045288df60da92fea2968 by david.green
[InstCombine] Canonicalize sadd.with.overflow with clamp to sadd.sat
This adds to D69245, adding extra signed patterns for folding from a
sadd_with_overflow to a sadd_sat. These are more complex than the
unsigned patterns, as the overflow can occur in either direction.
For the add case, the positive overflow can only occur if both of the
values are positive (same for both the values being negative). So there
is an extra select on whether to use the positive or negative overflow
limit.
Differential Revision: https://reviews.llvm.org/D69252
The file was modifiedllvm/lib/Transforms/InstCombine/InstCombineSelect.cpp
The file was modifiedllvm/test/Transforms/InstCombine/overflow_to_sat.ll
Commit 08390c52a2902502cd9b25472aa4c6380230c18e by david.green
[InstCombine] Canonicalize ssub.with.overflow with clamp to ssub.sat
Working on top of D69252, this adds canonicalisation patterns for
ssub.with.overflow to ssub.sats.
Differential Revision: https://reviews.llvm.org/D69753
The file was modifiedllvm/lib/Transforms/InstCombine/InstCombineSelect.cpp
The file was modifiedllvm/test/Transforms/InstCombine/overflow_to_sat.ll
Commit f5870b0f36bec3579e54994abcca9b809c056e1b by spatel
[SimplifyCFG] add tests for possible FP speculative select; NFC
It doesn't seem that there are any perf/param knobs that can be turned
to create selects for the FP variants of the tests, but that may not
always be true in the future. If it changes, we should propagate FMF.
The file was modifiedllvm/test/Transforms/SimplifyCFG/SpeculativeExec.ll
Commit 23f736059c704b95643dfc63425444044b57a973 by spatel
[SimplifyCFG] add fast-math-flags to tests for better coverage; NFC
The conversion to select fails to propagate FMF.
The file was modifiedllvm/test/Transforms/SimplifyCFG/speculate-math.ll
Commit ebf9bf2cbc8fa68d536e481e370c4ba40ce61a8a by spatel
[SimplifyCFG] propagate fast-math-flags (FMF) from phi to select
Similar to/extension of D70208 (rGee0882bdf866), but this one may
finally allow closing motivating bugs.
This is another step towards having FMF apply only to FP values rather
than those + fcmp. See PR38086 for one of the original
discussions/motivations: https://bugs.llvm.org/show_bug.cgi?id=38086
And the test here is derived from PR39535:
https://bugs.llvm.org/show_bug.cgi?id=39535
Currently, we lose FMF when converting any phi to select in SimplifyCFG.
There are a small number of similar changes needed to correct within
SimplifyCFG, so it should be quick to patch this pass up.
FMF was extended to select and phi with: D61917 D67564
The file was modifiedllvm/test/Transforms/SimplifyCFG/speculate-math.ll
The file was modifiedllvm/lib/Transforms/Utils/SimplifyCFG.cpp