summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen
diff options
context:
space:
mode:
authorCraig Topper <craig.topper@intel.com>2017-09-21 17:30:02 +0000
committerCraig Topper <craig.topper@intel.com>2017-09-21 17:30:02 +0000
commit280f1337736b3a3f35560cb31d43bfe01d88d57d (patch)
tree07b2c0f460b39e66a6696fc744ce7937ead090b5 /llvm/lib/CodeGen
parent50ce30c4f4f84807ecba5958ca3c677fd6c0e7d6 (diff)
downloadbcm5719-llvm-280f1337736b3a3f35560cb31d43bfe01d88d57d.tar.gz
bcm5719-llvm-280f1337736b3a3f35560cb31d43bfe01d88d57d.zip
[DAGCombiner] Remove duplicate code from visitZERO_EXTEND
This exact block of code exists right below. Differential Revision: https://reviews.llvm.org/D38122 llvm-svn: 313891
Diffstat (limited to 'llvm/lib/CodeGen')
-rw-r--r--llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp14
1 files changed, 0 insertions, 14 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp b/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
index 018ea1b48b8..d9b56bfa897 100644
--- a/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
+++ b/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
@@ -7558,20 +7558,6 @@ SDValue DAGCombiner::visitZERO_EXTEND(SDNode *N) {
return DAG.getZExtOrTrunc(Op, SDLoc(N), VT);
}
- // fold (zext (truncate (load x))) -> (zext (smaller load x))
- // fold (zext (truncate (srl (load x), c))) -> (zext (small load (x+c/n)))
- if (N0.getOpcode() == ISD::TRUNCATE) {
- if (SDValue NarrowLoad = ReduceLoadWidth(N0.getNode())) {
- SDNode *oye = N0.getOperand(0).getNode();
- if (NarrowLoad.getNode() != N0.getNode()) {
- CombineTo(N0.getNode(), NarrowLoad);
- // CombineTo deleted the truncate, if needed, but not what's under it.
- AddToWorklist(oye);
- }
- return SDValue(N, 0); // Return N so it doesn't get rechecked!
- }
- }
-
// fold (zext (truncate x)) -> (and x, mask)
if (N0.getOpcode() == ISD::TRUNCATE) {
// fold (zext (truncate (load x))) -> (zext (smaller load x))
OpenPOWER on IntegriCloud