Codegen support for fastcall & stdcall CC.
Patch by Ilya Okonsky!
llvm-svn: 59080
diff --git a/clang/lib/CodeGen/CodeGenModule.cpp b/clang/lib/CodeGen/CodeGenModule.cpp
index 3555ccd..c4877a6 100644
--- a/clang/lib/CodeGen/CodeGenModule.cpp
+++ b/clang/lib/CodeGen/CodeGenModule.cpp
@@ -252,7 +252,10 @@
// Set the appropriate calling convention for the Function.
if (D->getAttr<FastCallAttr>())
- F->setCallingConv(llvm::CallingConv::Fast);
+ F->setCallingConv(llvm::CallingConv::X86_FastCall);
+
+ if (D->getAttr<StdCallAttr>())
+ F->setCallingConv(llvm::CallingConv::X86_StdCall);
}
/// SetFunctionAttributesForDefinition - Set function attributes