[llvm-commits] [llvm] r60409 - /llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
Tilmann Scheller
tilmann.scheller at googlemail.com
Tue Dec 2 04:12:28 PST 2008
Author: tilmann
Date: Tue Dec 2 06:12:25 2008
New Revision: 60409
URL: http://llvm.org/viewvc/llvm-project?rev=60409&view=rev
Log:
make it possible to custom lower TRUNCATE (needed for the CellSPU target)
Modified:
llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
Modified: llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp?rev=60409&r1=60408&r2=60409&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp (original)
+++ llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp Tue Dec 2 06:12:25 2008
@@ -3904,6 +3904,11 @@
case Legal:
Tmp1 = LegalizeOp(Node->getOperand(0));
Result = DAG.UpdateNodeOperands(Result, Tmp1);
+ if (TLI.getOperationAction(Node->getOpcode(), Node->getValueType(0)) ==
+ TargetLowering::Custom) {
+ Tmp1 = TLI.LowerOperation(Result, DAG);
+ if (Tmp1.getNode()) Result = Tmp1;
+ }
break;
case Expand:
ExpandOp(Node->getOperand(0), Tmp1, Tmp2);
More information about the llvm-commits
mailing list