return Result;
}
+/// AddVariableConstraints - Look at AsmExpr and if it is a variable declared
+/// as using a particular register add that as a constraint that will be used
+/// in this asm stmt.
static std::string
-AddVariableConstraits(const std::string &Constraint, const Expr &AsmExpr,
- const TargetInfo &Target, CodeGenModule &CGM,
- const AsmStmt &Stmt) {
+AddVariableConstraints(const std::string &Constraint, const Expr &AsmExpr,
+ const TargetInfo &Target, CodeGenModule &CGM,
+ const AsmStmt &Stmt) {
const DeclRefExpr *AsmDeclRef = dyn_cast<DeclRefExpr>(&AsmExpr);
if (!AsmDeclRef)
return Constraint;
const Expr *OutExpr = S.getOutputExpr(i);
OutExpr = OutExpr->IgnoreParenNoopCasts(getContext());
- OutputConstraint = AddVariableConstraits(OutputConstraint, *OutExpr, Target,
+ OutputConstraint = AddVariableConstraints(OutputConstraint, *OutExpr, Target,
CGM, S);
LValue Dest = EmitLValue(OutExpr);
&OutputConstraintInfos);
InputConstraint =
- AddVariableConstraits(InputConstraint,
+ AddVariableConstraints(InputConstraint,
*InputExpr->IgnoreParenNoopCasts(getContext()),
Target, CGM, S);