[llvm-commits] CVS: llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp

Evan Cheng evan.cheng at apple.com
Sat Mar 4 23:30:29 PST 2006



Changes in directory llvm/lib/CodeGen/SelectionDAG:

DAGCombiner.cpp updated: 1.121 -> 1.122
---
Log message:

Back out fold (shl (add x, c1), c2) -> (add (shl x, c2), c1<<c2) for now.
It's causing an infinite loop compiling ldecod on x86 / Darwin.


---
Diffs of the changes:  (+0 -7)

 DAGCombiner.cpp |    7 -------
 1 files changed, 7 deletions(-)


Index: llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
diff -u llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp:1.121 llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp:1.122
--- llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp:1.121	Sat Mar  4 23:30:57 2006
+++ llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp	Sun Mar  5 01:30:16 2006
@@ -1454,13 +1454,6 @@
   if (N1C && N0.getOpcode() == ISD::SRA && N1 == N0.getOperand(1))
     return DAG.getNode(ISD::AND, VT, N0.getOperand(0),
                        DAG.getConstant(~0ULL << N1C->getValue(), VT));
-  // fold (shl (add x, c1), c2) -> (add (shl x, c2), c1<<c2)
-  if (N1C && N0.getOpcode() == ISD::ADD && N0.Val->hasOneUse() && 
-      isa<ConstantSDNode>(N0.getOperand(1))) {
-    return DAG.getNode(ISD::ADD, VT, 
-                       DAG.getNode(ISD::SHL, VT, N0.getOperand(0), N1),
-                       DAG.getNode(ISD::SHL, VT, N0.getOperand(1), N1));
-  }
   return SDOperand();
 }
 






More information about the llvm-commits mailing list