diff options
| author | Craig Topper <craig.topper@intel.com> | 2018-08-12 05:34:15 +0000 |
|---|---|---|
| committer | Craig Topper <craig.topper@intel.com> | 2018-08-12 05:34:15 +0000 |
| commit | d11220600496a8ed14cbd82d71e5736e910d4728 (patch) | |
| tree | 09c20156e27bfce7105974a5d6c7526d5137b353 /llvm/lib | |
| parent | ed8a114c86d8f6fd8d25701ef248c9e759d68950 (diff) | |
| download | bcm5719-llvm-d11220600496a8ed14cbd82d71e5736e910d4728.tar.gz bcm5719-llvm-d11220600496a8ed14cbd82d71e5736e910d4728.zip | |
[TargetLowering] Use APInt::isSubsetOf to simplify some code. NFC
llvm-svn: 339508
Diffstat (limited to 'llvm/lib')
| -rw-r--r-- | llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp b/llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp index 9120555d7db..75485977d6a 100644 --- a/llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp +++ b/llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp @@ -680,7 +680,7 @@ bool TargetLowering::SimplifyDemandedBits(SDValue Op, // If all of the unknown bits are known to be zero on one side or the other // (but not both) turn this into an *inclusive* or. // e.g. (A & C1)^(B & C2) -> (A & C1)|(B & C2) iff C1&C2 == 0 - if ((NewMask & ~Known.Zero & ~Known2.Zero) == 0) + if (NewMask.isSubsetOf(Known.Zero|Known2.Zero)) return TLO.CombineTo(Op, TLO.DAG.getNode(ISD::OR, dl, VT, Op.getOperand(0), Op.getOperand(1))); |

