mirror of
https://github.com/ldc-developers/ldc.git
synced 2025-05-04 09:00:33 +03:00
Merge branch 'master' into merge-2.064
Conflicts: dmd2/root/rmem.c
This commit is contained in:
commit
731f2a8fdf
10 changed files with 17 additions and 565 deletions
|
@ -379,25 +379,23 @@ LLFunction* DtoInlineIRFunction(FuncDeclaration* fdecl)
|
|||
static llvm::FunctionType* DtoVaFunctionType(FuncDeclaration* fdecl)
|
||||
{
|
||||
IrFuncTy &irFty = fdecl->irFty;
|
||||
LLFunctionType* type = 0;
|
||||
if (irFty.funcType) return irFty.funcType;
|
||||
|
||||
// create new ir funcTy
|
||||
irFty.reset();
|
||||
irFty.ret = new IrFuncTyArg(Type::tvoid, false);
|
||||
|
||||
irFty.args.push_back(new IrFuncTyArg(Type::tvoid->pointerTo(), false));
|
||||
|
||||
if (fdecl->llvmInternal == LLVMva_start)
|
||||
type = GET_INTRINSIC_DECL(vastart)->getFunctionType();
|
||||
irFty.funcType = GET_INTRINSIC_DECL(vastart)->getFunctionType();
|
||||
else if (fdecl->llvmInternal == LLVMva_copy) {
|
||||
type = GET_INTRINSIC_DECL(vacopy)->getFunctionType();
|
||||
irFty.funcType = GET_INTRINSIC_DECL(vacopy)->getFunctionType();
|
||||
irFty.args.push_back(new IrFuncTyArg(Type::tvoid->pointerTo(), false));
|
||||
}
|
||||
else if (fdecl->llvmInternal == LLVMva_end)
|
||||
type = GET_INTRINSIC_DECL(vaend)->getFunctionType();
|
||||
assert(type);
|
||||
irFty.funcType = GET_INTRINSIC_DECL(vaend)->getFunctionType();
|
||||
assert(irFty.funcType);
|
||||
|
||||
return type;
|
||||
return irFty.funcType;
|
||||
}
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue