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

Nate Begeman natebegeman at mac.com
Mon Dec 12 19:03:34 PST 2005



Changes in directory llvm/lib/CodeGen/SelectionDAG:

LegalizeDAG.cpp updated: 1.227 -> 1.228
---
Log message:

Lowering constant pool entries on ppc exposed a bug in the recently added
ConstantVec legalizing code, which would return constantpool nodes that
were not of the target's pointer type.


---
Diffs of the changes:  (+1 -1)

 LegalizeDAG.cpp |    2 +-
 1 files changed, 1 insertion(+), 1 deletion(-)


Index: llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
diff -u llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp:1.227 llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp:1.228
--- llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp:1.227	Mon Dec 12 16:27:43 2005
+++ llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp	Mon Dec 12 21:03:23 2005
@@ -714,7 +714,7 @@
                                        cast<ConstantSDNode>(OpN)->getValue()));
     }
     Constant *CP = ConstantPacked::get(CV);
-    SDOperand CPIdx = DAG.getConstantPool(CP, Node->getValueType(0));
+    SDOperand CPIdx = LegalizeOp(DAG.getConstantPool(CP, TLI.getPointerTy()));
     Result = DAG.getLoad(VT, DAG.getEntryNode(), CPIdx, DAG.getSrcValue(NULL));
     break;
   }






More information about the llvm-commits mailing list