[PATCH] D59208: [DAGCombiner] fold (addcarry (xor a, -1), b, c) -> (subcarry b, a, !c) and flip carry.
Simon Pilgrim via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Jul 1 07:17:25 PDT 2019
RKSimon added inline comments.
================
Comment at: lib/CodeGen/SelectionDAG/DAGCombiner.cpp:2413
case TargetLowering::ZeroOrNegativeOneBooleanContent:
- Cst = DAG.getConstant(-1, DL, VT);
+ Cst = DAG.getAllOnesConstant(DL, VT);
break;
----------------
NFC - this can be committed straight away?
================
Comment at: lib/CodeGen/SelectionDAG/DAGCombiner.cpp:2423
+ bool Force = true) {
+ if (Force && isa<ConstantSDNode>(V.getNode()))
+ return flipBoolean(V, SDLoc(V), DAG, TLI);
----------------
Drop unnecessary getNode() ?
Repository:
rL LLVM
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D59208/new/
https://reviews.llvm.org/D59208
More information about the llvm-commits
mailing list