[PATCH] D42808: [X86] Teach DAG unfoldMemoryOperand to reconvert CMPs to tests
Craig Topper via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Feb 2 09:27:42 PST 2018
craig.topper added inline comments.
================
Comment at: llvm/lib/Target/X86/X86InstrInfo.cpp:9237
+ if (auto *C = dyn_cast<ConstantSDNode>(BeforeOps[1].getNode())) {
+ if(C->getConstantIntValue()->isZeroValue()) {
+ switch (Opc) {
----------------
Any reason this can't be C->isNullValue()?
Or even just use isNullConstant to merge the first and second if.
Repository:
rL LLVM
https://reviews.llvm.org/D42808
More information about the llvm-commits
mailing list