mirror of
https://github.com/ldc-developers/ldc.git
synced 2025-05-03 08:30:47 +03:00
Updated to latest LLVM trunk, function notes have been removed and merged with parameter attributes, which have been renamed to just attributes. Nothing seems to have broke!
This commit is contained in:
parent
e7ad7296d0
commit
bce9368514
12 changed files with 119 additions and 134 deletions
|
@ -758,10 +758,10 @@ static LLValue* DtoArrayEqCmp_impl(Loc& loc, const char* func, DValue* l, DValue
|
|||
CallOrInvoke* call = gIR->CreateCallOrInvoke(fn, args.begin(), args.end(), "tmp");
|
||||
|
||||
// set param attrs
|
||||
llvm::PAListPtr palist;
|
||||
palist = palist.addAttr(1, llvm::ParamAttr::ByVal);
|
||||
palist = palist.addAttr(2, llvm::ParamAttr::ByVal);
|
||||
call->setParamAttrs(palist);
|
||||
llvm::AttrListPtr palist;
|
||||
palist = palist.addAttr(1, llvm::Attribute::ByVal);
|
||||
palist = palist.addAttr(2, llvm::Attribute::ByVal);
|
||||
call->setAttributes(palist);
|
||||
|
||||
return call->get();
|
||||
}
|
||||
|
@ -1072,7 +1072,7 @@ void DtoArrayBoundsCheck(Loc& loc, DValue* arr, DValue* index, bool isslice)
|
|||
gIR->scope() = IRScope(failbb, okbb);
|
||||
|
||||
std::vector<LLValue*> args;
|
||||
llvm::PAListPtr palist;
|
||||
llvm::AttrListPtr palist;
|
||||
|
||||
// file param
|
||||
// FIXME: every array bounds check creates a global for the filename !!!
|
||||
|
@ -1090,7 +1090,7 @@ void DtoArrayBoundsCheck(Loc& loc, DValue* arr, DValue* index, bool isslice)
|
|||
DtoStore(c->getOperand(1), ptr);
|
||||
|
||||
args.push_back(alloc);
|
||||
palist = palist.addAttr(1, llvm::ParamAttr::ByVal);
|
||||
palist = palist.addAttr(1, llvm::Attribute::ByVal);
|
||||
|
||||
// line param
|
||||
c = DtoConstUint(loc.linnum);
|
||||
|
@ -1099,7 +1099,7 @@ void DtoArrayBoundsCheck(Loc& loc, DValue* arr, DValue* index, bool isslice)
|
|||
// call
|
||||
llvm::Function* errorfn = LLVM_D_GetRuntimeFunction(gIR->module, "_d_array_bounds");
|
||||
CallOrInvoke* call = gIR->CreateCallOrInvoke(errorfn, args.begin(), args.end());
|
||||
call->setParamAttrs(palist);
|
||||
call->setAttributes(palist);
|
||||
|
||||
// the function does not return
|
||||
gIR->ir->CreateUnreachable();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue