diff options
Diffstat (limited to 'lib/CodeGen/SelectionDAG/TargetLowering.cpp')
-rw-r--r-- | lib/CodeGen/SelectionDAG/TargetLowering.cpp | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/lib/CodeGen/SelectionDAG/TargetLowering.cpp b/lib/CodeGen/SelectionDAG/TargetLowering.cpp index ee1c4acad9..129bcd9525 100644 --- a/lib/CodeGen/SelectionDAG/TargetLowering.cpp +++ b/lib/CodeGen/SelectionDAG/TargetLowering.cpp @@ -1300,18 +1300,21 @@ TargetLowering::getConstraintType(char ConstraintLetter) const { } } -bool TargetLowering::isOperandValidForConstraint(SDOperand Op, - char ConstraintLetter) { +/// isOperandValidForConstraint - Return the specified operand (possibly +/// modified) if the specified SDOperand is valid for the specified target +/// constraint letter, otherwise return null. +SDOperand TargetLowering::isOperandValidForConstraint(SDOperand Op, + char ConstraintLetter, + SelectionDAG &DAG) { switch (ConstraintLetter) { - default: return false; + default: return SDOperand(0,0); case 'i': // Simple Integer or Relocatable Constant case 'n': // Simple Integer case 's': // Relocatable Constant - return true; // FIXME: not right. + return Op; // FIXME: not right. } } - std::vector<unsigned> TargetLowering:: getRegClassForInlineAsmConstraint(const std::string &Constraint, MVT::ValueType VT) const { |