summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
diff options
context:
space:
mode:
authorCraig Topper <craig.topper@gmail.com>2017-04-28 03:36:24 +0000
committerCraig Topper <craig.topper@gmail.com>2017-04-28 03:36:24 +0000
commit24e71017aa3a062e6c2b055038ab9ed0ad2d35ae (patch)
tree461d640d885493861683e8350040434e9a912a74 /llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
parentf74d946624f30d60fd3f90a9545a455308931c32 (diff)
downloadbcm5719-llvm-24e71017aa3a062e6c2b055038ab9ed0ad2d35ae.tar.gz
bcm5719-llvm-24e71017aa3a062e6c2b055038ab9ed0ad2d35ae.zip
[APInt] Use inplace shift methods where possible. NFCI
llvm-svn: 301612
Diffstat (limited to 'llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp')
-rw-r--r--llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp b/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
index 0c289714c8f..91ce16bb049 100644
--- a/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
+++ b/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
@@ -5364,7 +5364,7 @@ SDValue DAGCombiner::visitSHL(SDNode *N) {
APInt Mask = APInt::getHighBitsSet(OpSizeInBits, OpSizeInBits - c1);
SDValue Shift;
if (c2 > c1) {
- Mask = Mask.shl(c2 - c1);
+ Mask <<= c2 - c1;
SDLoc DL(N);
Shift = DAG.getNode(ISD::SHL, DL, VT, N0.getOperand(0),
DAG.getConstant(c2 - c1, DL, N1.getValueType()));
OpenPOWER on IntegriCloud