[PATCH] D111530: [TargetLowering] Optimize expanded SRL/SHL fed into SETCC ne/eq 0
Simon Pilgrim via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Nov 8 08:13:08 PST 2021
RKSimon added inline comments.
================
Comment at: llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp:4153
// all bits clear: (X | (Y<<32)) == 0 --> (X | Y) == 0
// all bits set: (X | (Y<<32)) == -1 --> (X & Y) == -1
bool CmpZero = N1C->getAPIntValue().isZero();
----------------
This is doing something pretty similar, its more limited to the 'concat' pattern but handles the -1 'allbits' case as well.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D111530/new/
https://reviews.llvm.org/D111530
More information about the llvm-commits
mailing list