aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Frontend/InitPreprocessor.cpp
diff options
context:
space:
mode:
authorSanjay Patel <spatel@rotateright.com>2022-02-17 10:34:48 -0500
committerSanjay Patel <spatel@rotateright.com>2022-02-17 10:36:37 -0500
commit58df2da0540c0ae0bb4f72c382fae0b4fbedae1c (patch)
treed8db7a3e322e0b0638b2834f76305c981c87eded /clang/lib/Frontend/InitPreprocessor.cpp
parent234a8422c912ec102e23cc06999245945b53182f (diff)
downloadllvm-58df2da0540c0ae0bb4f72c382fae0b4fbedae1c.zip
llvm-58df2da0540c0ae0bb4f72c382fae0b4fbedae1c.tar.gz
llvm-58df2da0540c0ae0bb4f72c382fae0b4fbedae1c.tar.bz2
[InstCombine] push constant operand down/outside in sequence of min/max intrinsics
A generalization like this was suggested in D119754. This is the inverse direction of D119851, and we get all of the folds there plus the one that was missed. There is precedence for this kind of transform in instcombine with "or" instructions (but strangely only with that one opcode AFAICT). Similar justification as in the other patch: The line between instcombine and reassociate for these kinds of folds is blurry. This doesn't appear to have much cost and gives us the expected wins from repeated folds as seen in the last set of test diffs. Differential Revision: https://reviews.llvm.org/D119955
Diffstat (limited to 'clang/lib/Frontend/InitPreprocessor.cpp')
0 files changed, 0 insertions, 0 deletions