When CVP determines that a with.overflow intrinsic cannot overflow, it currently inserts a simple add/sub. As we already determined that there can be no overflow, we should add the appropriate NUW/NSW flag.
Details
Details
Diff Detail
Diff Detail
Paths
| Differential D60585
[CVP] Set NSW/NUW flags when simplifying with.overflow ClosedPublic Authored by nikic on Apr 11 2019, 2:18 PM.
Details Summary When CVP determines that a with.overflow intrinsic cannot overflow, it currently inserts a simple add/sub. As we already determined that there can be no overflow, we should add the appropriate NUW/NSW flag.
Diff Detail Event TimelineThis revision is now accepted and ready to land.Apr 11 2019, 3:53 PM Closed by commit rL358298: [CVP] Set NSW/NUW flags when simplifying with.overflow (authored by nikic). · Explain WhyApr 12 2019, 11:18 AM This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 194757 llvm/lib/Transforms/Scalar/CorrelatedValuePropagation.cpp
llvm/test/Transforms/CorrelatedValuePropagation/overflows.ll
|