summaryrefslogtreecommitdiffstats
path: root/llvm/test/Transforms/InstCombine/unsigned_saturated_sub.ll
Commit message (Collapse)AuthorAgeFilesLines
* [InstCombine] Expand usub_sat patterns to handle constantsDavid Green2019-11-301-19/+14
| | | | | | | | The constants come through as add %x, -C, not a sub as would be expected. They need some extra matchers to canonicalise them towards usub_sat. Differential Revision: https://reviews.llvm.org/D69514
* [InstCombine] Adjust usub_sat fold one use checksDavid Green2019-11-301-10/+9
| | | | | | This adjusts the one use checks in the the usub_sat fold code to not increase instruction count, but otherwise do the fold. Reviewed as a part of D69514.
* [InstCombine] More usub_sat tests. NFC.David Green2019-11-301-0/+299
|
* Revert "Temporarily Revert "Add basic loop fusion pass.""Eric Christopher2019-04-171-0/+160
| | | | | | | | The reversion apparently deleted the test/Transforms directory. Will be re-reverting again. llvm-svn: 358552
* Temporarily Revert "Add basic loop fusion pass."Eric Christopher2019-04-171-160/+0
| | | | | | | | As it's causing some bot failures (and per request from kbarton). This reverts commit r358543/ab70da07286e618016e78247e4a24fcb84077fda. llvm-svn: 358546
* [InstCombine] Use uadd.sat and usub.sat for canonicalizationNikita Popov2019-03-271-54/+36
| | | | | | | | | | | | | Start using the uadd.sat and usub.sat intrinsics for the existing canonicalizations. These intrinsics should optimize better than expanded IR, have better handling in the X86 backend and should be no worse than expanded IR in other backends, as far as we know. rL357012 already introduced use of uadd.sat for the add+umin pattern. Differential Revision: https://reviews.llvm.org/D58872 llvm-svn: 357103
* [InstCombine] add unsigned saturation subtraction canonicalizationsSanjay Patel2018-02-051-36/+51
| | | | | | | | | | | | | | | | | | | | | | | | This is the instcombine part of unsigned saturation canonicalization. Backend patches already commited: https://reviews.llvm.org/D37510 https://reviews.llvm.org/D37534 It converts unsigned saturated subtraction patterns to forms recognized by the backend: (a > b) ? a - b : 0 -> ((a > b) ? a : b) - b) (b < a) ? a - b : 0 -> ((a > b) ? a : b) - b) (b > a) ? 0 : a - b -> ((a > b) ? a : b) - b) (a < b) ? 0 : a - b -> ((a > b) ? a : b) - b) ((a > b) ? b - a : 0) -> - ((a > b) ? a : b) - b) ((b < a) ? b - a : 0) -> - ((a > b) ? a : b) - b) ((b > a) ? 0 : b - a) -> - ((a > b) ? a : b) - b) ((a < b) ? 0 : b - a) -> - ((a > b) ? a : b) - b) Patch by Yulia Koval! Differential Revision: https://reviews.llvm.org/D41480 llvm-svn: 324255
* [InstCombine] make sure tests are providing coverage for the stated pattern; NFCSanjay Patel2018-02-021-48/+68
| | | | | | | | Without extra instructions and uses, swapMayExposeCSEOpportunities() would change the icmp (as seen in the check lines), so we were not actually testing patterns that should be handled by D41480. llvm-svn: 324143
* [InstCombine] add baseline tests for unsigned saturated sub (D41480); NFCSanjay Patel2018-02-021-0/+143
llvm-svn: 324109
OpenPOWER on IntegriCloud