diff options
author | Sanjay Patel <spatel@rotateright.com> | 2021-08-21 13:05:35 -0400 |
---|---|---|
committer | Sanjay Patel <spatel@rotateright.com> | 2021-08-22 07:18:31 -0400 |
commit | 3aa009cc87e3789ac44bbb98b04846736373e08f (patch) | |
tree | 7bcfe08dc66a955b055ac83338e41619cb89318f /llvm/lib/Transforms/Utils/LoopUnrollRuntime.cpp | |
parent | 7f48bd3bed9540cc4c72091dfb38e40dfac24aa4 (diff) | |
download | llvm-3aa009cc87e3789ac44bbb98b04846736373e08f.zip llvm-3aa009cc87e3789ac44bbb98b04846736373e08f.tar.gz llvm-3aa009cc87e3789ac44bbb98b04846736373e08f.tar.bz2 |
[InstCombine] generalize subtract with 'not' operands
The motivation was to get min/max intrinsics to parity
with cmp+select idioms, but this unlocks a few more
folds because isFreeToInvert recognizes add/sub with
constants too.
In the min/max example, we have too many extra uses
for smaller folds to improve things, but this fold
is able to eliminate uses even though we can't reduce
the number of instructions.
Diffstat (limited to 'llvm/lib/Transforms/Utils/LoopUnrollRuntime.cpp')
0 files changed, 0 insertions, 0 deletions