diff options
author | Chad Rosier <mcrosier@apple.com> | 2012-08-23 20:00:18 +0000 |
---|---|---|
committer | Chad Rosier <mcrosier@apple.com> | 2012-08-23 20:00:18 +0000 |
commit | 42b60551eff3a424e191b293bfd606559dc96bff (patch) | |
tree | fcfc2120bdd36127598d9f19831a28277518d0e9 | |
parent | b66529d04727dc686b97ea3d937fc9785792f505 (diff) |
[ms-inline asm] Remove an unused argument. This logic can now be reused by the
ms-style inline asms.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@162463 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | lib/CodeGen/CGStmt.cpp | 11 | ||||
-rw-r--r-- | lib/CodeGen/CodeGenFunction.h | 6 |
2 files changed, 7 insertions, 10 deletions
diff --git a/lib/CodeGen/CGStmt.cpp b/lib/CodeGen/CGStmt.cpp index 4c24d2b391..c07fbf0454 100644 --- a/lib/CodeGen/CGStmt.cpp +++ b/lib/CodeGen/CGStmt.cpp @@ -1323,8 +1323,7 @@ AddVariableConstraints(const std::string &Constraint, const Expr &AsmExpr, } llvm::Value* -CodeGenFunction::EmitAsmInputLValue(const AsmStmt &S, - const TargetInfo::ConstraintInfo &Info, +CodeGenFunction::EmitAsmInputLValue(const TargetInfo::ConstraintInfo &Info, LValue InputValue, QualType InputType, std::string &ConstraintStr) { llvm::Value *Arg; @@ -1353,7 +1352,7 @@ CodeGenFunction::EmitAsmInputLValue(const AsmStmt &S, return Arg; } -llvm::Value* CodeGenFunction::EmitAsmInput(const AsmStmt &S, +llvm::Value* CodeGenFunction::EmitAsmInput( const TargetInfo::ConstraintInfo &Info, const Expr *InputExpr, std::string &ConstraintStr) { @@ -1363,7 +1362,7 @@ llvm::Value* CodeGenFunction::EmitAsmInput(const AsmStmt &S, InputExpr = InputExpr->IgnoreParenNoopCasts(getContext()); LValue Dest = EmitLValue(InputExpr); - return EmitAsmInputLValue(S, Info, Dest, InputExpr->getType(), ConstraintStr); + return EmitAsmInputLValue(Info, Dest, InputExpr->getType(), ConstraintStr); } /// getAsmSrcLocInfo - Return the !srcloc metadata node to attach to an inline @@ -1511,7 +1510,7 @@ void CodeGenFunction::EmitAsmStmt(const AsmStmt &S) { InOutConstraints += ','; const Expr *InputExpr = S.getOutputExpr(i); - llvm::Value *Arg = EmitAsmInputLValue(S, Info, Dest, InputExpr->getType(), + llvm::Value *Arg = EmitAsmInputLValue(Info, Dest, InputExpr->getType(), InOutConstraints); if (llvm::Type* AdjTy = @@ -1549,7 +1548,7 @@ void CodeGenFunction::EmitAsmStmt(const AsmStmt &S) { *InputExpr->IgnoreParenNoopCasts(getContext()), Target, CGM, S); - llvm::Value *Arg = EmitAsmInput(S, Info, InputExpr, Constraints); + llvm::Value *Arg = EmitAsmInput(Info, InputExpr, Constraints); // If this input argument is tied to a larger output result, extend the // input to be the same size as the output. The LLVM backend wants to see diff --git a/lib/CodeGen/CodeGenFunction.h b/lib/CodeGen/CodeGenFunction.h index 0b7748b3c6..5855555782 100644 --- a/lib/CodeGen/CodeGenFunction.h +++ b/lib/CodeGen/CodeGenFunction.h @@ -2552,12 +2552,10 @@ private: SmallVector<llvm::Value*, 16> &Args, llvm::FunctionType *IRFuncTy); - llvm::Value* EmitAsmInput(const AsmStmt &S, - const TargetInfo::ConstraintInfo &Info, + llvm::Value* EmitAsmInput(const TargetInfo::ConstraintInfo &Info, const Expr *InputExpr, std::string &ConstraintStr); - llvm::Value* EmitAsmInputLValue(const AsmStmt &S, - const TargetInfo::ConstraintInfo &Info, + llvm::Value* EmitAsmInputLValue(const TargetInfo::ConstraintInfo &Info, LValue InputValue, QualType InputType, std::string &ConstraintStr); |