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

Chris Lattner sabre at nondot.org
Tue Oct 31 11:41:32 PST 2006



Changes in directory llvm/lib/CodeGen/SelectionDAG:

SelectionDAGISel.cpp updated: 1.309 -> 1.310
---
Log message:

TargetLowering::isOperandValidForConstraint


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

 SelectionDAGISel.cpp |    9 +++++++--
 1 files changed, 7 insertions(+), 2 deletions(-)


Index: llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp
diff -u llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp:1.309 llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp:1.310
--- llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp:1.309	Tue Oct 31 01:33:13 2006
+++ llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp	Tue Oct 31 13:41:18 2006
@@ -2487,8 +2487,13 @@
         CTy = TLI.getConstraintType(ConstraintCode[0]);
         
       if (CTy == TargetLowering::C_Other) {
-        if (!TLI.isOperandValidForConstraint(InOperandVal, ConstraintCode[0]))
-          assert(0 && "MATCH FAIL!");
+        InOperandVal = TLI.isOperandValidForConstraint(InOperandVal,
+                                                       ConstraintCode[0], DAG);
+        if (!InOperandVal.Val) {
+          std::cerr << "Invalid operand for inline asm constraint '"
+                    << ConstraintCode << "'!\n";
+          exit(1);
+        }
         
         // Add information to the INLINEASM node to know about this input.
         unsigned ResOpType = 3 /*IMM*/ | (1 << 3);






More information about the llvm-commits mailing list