Rename llvm::Attributes to llvm::Attribute.

llvm-svn: 170722
This commit is contained in:
Bill Wendling 2012-12-20 19:27:06 +00:00
parent 4442605f18
commit 207f05369d
12 changed files with 85 additions and 85 deletions

View File

@ -971,46 +971,46 @@ void CodeGenModule::ConstructAttributeList(const CGFunctionInfo &FI,
CallingConv = FI.getEffectiveCallingConvention();
if (FI.isNoReturn())
FuncAttrs.addAttribute(llvm::Attributes::NoReturn);
FuncAttrs.addAttribute(llvm::Attribute::NoReturn);
// FIXME: handle sseregparm someday...
if (TargetDecl) {
if (TargetDecl->hasAttr<ReturnsTwiceAttr>())
FuncAttrs.addAttribute(llvm::Attributes::ReturnsTwice);
FuncAttrs.addAttribute(llvm::Attribute::ReturnsTwice);
if (TargetDecl->hasAttr<NoThrowAttr>())
FuncAttrs.addAttribute(llvm::Attributes::NoUnwind);
FuncAttrs.addAttribute(llvm::Attribute::NoUnwind);
else if (const FunctionDecl *Fn = dyn_cast<FunctionDecl>(TargetDecl)) {
const FunctionProtoType *FPT = Fn->getType()->getAs<FunctionProtoType>();
if (FPT && FPT->isNothrow(getContext()))
FuncAttrs.addAttribute(llvm::Attributes::NoUnwind);
FuncAttrs.addAttribute(llvm::Attribute::NoUnwind);
}
if (TargetDecl->hasAttr<NoReturnAttr>())
FuncAttrs.addAttribute(llvm::Attributes::NoReturn);
FuncAttrs.addAttribute(llvm::Attribute::NoReturn);
if (TargetDecl->hasAttr<ReturnsTwiceAttr>())
FuncAttrs.addAttribute(llvm::Attributes::ReturnsTwice);
FuncAttrs.addAttribute(llvm::Attribute::ReturnsTwice);
// 'const' and 'pure' attribute functions are also nounwind.
if (TargetDecl->hasAttr<ConstAttr>()) {
FuncAttrs.addAttribute(llvm::Attributes::ReadNone);
FuncAttrs.addAttribute(llvm::Attributes::NoUnwind);
FuncAttrs.addAttribute(llvm::Attribute::ReadNone);
FuncAttrs.addAttribute(llvm::Attribute::NoUnwind);
} else if (TargetDecl->hasAttr<PureAttr>()) {
FuncAttrs.addAttribute(llvm::Attributes::ReadOnly);
FuncAttrs.addAttribute(llvm::Attributes::NoUnwind);
FuncAttrs.addAttribute(llvm::Attribute::ReadOnly);
FuncAttrs.addAttribute(llvm::Attribute::NoUnwind);
}
if (TargetDecl->hasAttr<MallocAttr>())
RetAttrs.addAttribute(llvm::Attributes::NoAlias);
RetAttrs.addAttribute(llvm::Attribute::NoAlias);
}
if (CodeGenOpts.OptimizeSize)
FuncAttrs.addAttribute(llvm::Attributes::OptimizeForSize);
FuncAttrs.addAttribute(llvm::Attribute::OptimizeForSize);
if (CodeGenOpts.OptimizeSize == 2)
FuncAttrs.addAttribute(llvm::Attributes::MinSize);
FuncAttrs.addAttribute(llvm::Attribute::MinSize);
if (CodeGenOpts.DisableRedZone)
FuncAttrs.addAttribute(llvm::Attributes::NoRedZone);
FuncAttrs.addAttribute(llvm::Attribute::NoRedZone);
if (CodeGenOpts.NoImplicitFloat)
FuncAttrs.addAttribute(llvm::Attributes::NoImplicitFloat);
FuncAttrs.addAttribute(llvm::Attribute::NoImplicitFloat);
QualType RetTy = FI.getReturnType();
unsigned Index = 1;
@ -1018,9 +1018,9 @@ void CodeGenModule::ConstructAttributeList(const CGFunctionInfo &FI,
switch (RetAI.getKind()) {
case ABIArgInfo::Extend:
if (RetTy->hasSignedIntegerRepresentation())
RetAttrs.addAttribute(llvm::Attributes::SExt);
RetAttrs.addAttribute(llvm::Attribute::SExt);
else if (RetTy->hasUnsignedIntegerRepresentation())
RetAttrs.addAttribute(llvm::Attributes::ZExt);
RetAttrs.addAttribute(llvm::Attribute::ZExt);
break;
case ABIArgInfo::Direct:
case ABIArgInfo::Ignore:
@ -1028,18 +1028,18 @@ void CodeGenModule::ConstructAttributeList(const CGFunctionInfo &FI,
case ABIArgInfo::Indirect: {
llvm::AttrBuilder SRETAttrs;
SRETAttrs.addAttribute(llvm::Attributes::StructRet);
SRETAttrs.addAttribute(llvm::Attribute::StructRet);
if (RetAI.getInReg())
SRETAttrs.addAttribute(llvm::Attributes::InReg);
SRETAttrs.addAttribute(llvm::Attribute::InReg);
PAL.push_back(llvm::
AttributeWithIndex::get(Index,
llvm::Attributes::get(getLLVMContext(),
llvm::Attribute::get(getLLVMContext(),
SRETAttrs)));
++Index;
// sret disables readnone and readonly
FuncAttrs.removeAttribute(llvm::Attributes::ReadOnly)
.removeAttribute(llvm::Attributes::ReadNone);
FuncAttrs.removeAttribute(llvm::Attribute::ReadOnly)
.removeAttribute(llvm::Attribute::ReadNone);
break;
}
@ -1050,7 +1050,7 @@ void CodeGenModule::ConstructAttributeList(const CGFunctionInfo &FI,
if (RetAttrs.hasAttributes())
PAL.push_back(llvm::
AttributeWithIndex::get(llvm::AttributeSet::ReturnIndex,
llvm::Attributes::get(getLLVMContext(),
llvm::Attribute::get(getLLVMContext(),
RetAttrs)));
for (CGFunctionInfo::const_arg_iterator it = FI.arg_begin(),
@ -1062,9 +1062,9 @@ void CodeGenModule::ConstructAttributeList(const CGFunctionInfo &FI,
if (AI.getPaddingType()) {
if (AI.getPaddingInReg()) {
llvm::AttrBuilder PadAttrs;
PadAttrs.addAttribute(llvm::Attributes::InReg);
PadAttrs.addAttribute(llvm::Attribute::InReg);
llvm::Attributes A =llvm::Attributes::get(getLLVMContext(), PadAttrs);
llvm::Attribute A =llvm::Attribute::get(getLLVMContext(), PadAttrs);
PAL.push_back(llvm::AttributeWithIndex::get(Index, A));
}
// Increment Index if there is padding.
@ -1077,13 +1077,13 @@ void CodeGenModule::ConstructAttributeList(const CGFunctionInfo &FI,
switch (AI.getKind()) {
case ABIArgInfo::Extend:
if (ParamType->isSignedIntegerOrEnumerationType())
Attrs.addAttribute(llvm::Attributes::SExt);
Attrs.addAttribute(llvm::Attribute::SExt);
else if (ParamType->isUnsignedIntegerOrEnumerationType())
Attrs.addAttribute(llvm::Attributes::ZExt);
Attrs.addAttribute(llvm::Attribute::ZExt);
// FALL THROUGH
case ABIArgInfo::Direct:
if (AI.getInReg())
Attrs.addAttribute(llvm::Attributes::InReg);
Attrs.addAttribute(llvm::Attribute::InReg);
// FIXME: handle sseregparm someday...
@ -1093,7 +1093,7 @@ void CodeGenModule::ConstructAttributeList(const CGFunctionInfo &FI,
if (Attrs.hasAttributes())
for (unsigned I = 0; I < Extra; ++I)
PAL.push_back(llvm::AttributeWithIndex::get(Index + I,
llvm::Attributes::get(getLLVMContext(),
llvm::Attribute::get(getLLVMContext(),
Attrs)));
Index += Extra;
}
@ -1101,16 +1101,16 @@ void CodeGenModule::ConstructAttributeList(const CGFunctionInfo &FI,
case ABIArgInfo::Indirect:
if (AI.getInReg())
Attrs.addAttribute(llvm::Attributes::InReg);
Attrs.addAttribute(llvm::Attribute::InReg);
if (AI.getIndirectByVal())
Attrs.addAttribute(llvm::Attributes::ByVal);
Attrs.addAttribute(llvm::Attribute::ByVal);
Attrs.addAlignmentAttr(AI.getIndirectAlign());
// byval disables readnone and readonly.
FuncAttrs.removeAttribute(llvm::Attributes::ReadOnly)
.removeAttribute(llvm::Attributes::ReadNone);
FuncAttrs.removeAttribute(llvm::Attribute::ReadOnly)
.removeAttribute(llvm::Attribute::ReadNone);
break;
case ABIArgInfo::Ignore:
@ -1130,14 +1130,14 @@ void CodeGenModule::ConstructAttributeList(const CGFunctionInfo &FI,
if (Attrs.hasAttributes())
PAL.push_back(llvm::AttributeWithIndex::get(Index,
llvm::Attributes::get(getLLVMContext(),
llvm::Attribute::get(getLLVMContext(),
Attrs)));
++Index;
}
if (FuncAttrs.hasAttributes())
PAL.push_back(llvm::
AttributeWithIndex::get(llvm::AttributeSet::FunctionIndex,
llvm::Attributes::get(getLLVMContext(),
llvm::Attribute::get(getLLVMContext(),
FuncAttrs)));
}
@ -1186,8 +1186,8 @@ void CodeGenFunction::EmitFunctionProlog(const CGFunctionInfo &FI,
// Name the struct return argument.
if (CGM.ReturnTypeUsesSRet(FI)) {
AI->setName("agg.result");
AI->addAttr(llvm::Attributes::get(getLLVMContext(),
llvm::Attributes::NoAlias));
AI->addAttr(llvm::Attribute::get(getLLVMContext(),
llvm::Attribute::NoAlias));
++AI;
}
@ -1258,8 +1258,8 @@ void CodeGenFunction::EmitFunctionProlog(const CGFunctionInfo &FI,
llvm::Value *V = AI;
if (Arg->getType().isRestrictQualified())
AI->addAttr(llvm::Attributes::get(getLLVMContext(),
llvm::Attributes::NoAlias));
AI->addAttr(llvm::Attribute::get(getLLVMContext(),
llvm::Attribute::NoAlias));
// Ensure the argument is the correct type.
if (V->getType() != ArgI.getCoerceToType())
@ -2234,7 +2234,7 @@ RValue CodeGenFunction::EmitCall(const CGFunctionInfo &CallInfo,
AttributeList);
llvm::BasicBlock *InvokeDest = 0;
if (!Attrs.getFnAttributes().hasAttribute(llvm::Attributes::NoUnwind))
if (!Attrs.getFnAttributes().hasAttribute(llvm::Attribute::NoUnwind))
InvokeDest = getInvokeDest();
llvm::CallSite CS;

View File

@ -946,7 +946,7 @@ void CodeGenFunction::EmitDestructorBody(FunctionArgList &Args) {
// -fapple-kext must inline any call to this dtor into
// the caller's body.
if (getLangOpts().AppleKext)
CurFn->addFnAttr(llvm::Attributes::AlwaysInline);
CurFn->addFnAttr(llvm::Attribute::AlwaysInline);
break;
}

View File

@ -233,7 +233,7 @@ CreateGlobalInitOrDestructFunction(CodeGenModule &CGM,
Fn->setDoesNotThrow();
if (CGM.getLangOpts().SanitizeAddress)
Fn->addFnAttr(llvm::Attributes::AddressSafety);
Fn->addFnAttr(llvm::Attribute::AddressSafety);
return Fn;
}

View File

@ -2020,10 +2020,10 @@ void CodeGenFunction::EmitCheck(llvm::Value *Checked, StringRef CheckName,
llvm::FunctionType::get(CGM.VoidTy, ArgTypes, false);
llvm::AttrBuilder B;
if (!Recover) {
B.addAttribute(llvm::Attributes::NoReturn)
.addAttribute(llvm::Attributes::NoUnwind);
B.addAttribute(llvm::Attribute::NoReturn)
.addAttribute(llvm::Attribute::NoUnwind);
}
B.addAttribute(llvm::Attributes::UWTable);
B.addAttribute(llvm::Attribute::UWTable);
// Checks that have two variants use a suffix to differentiate them
bool NeedsAbortSuffix = (RecoverKind != CRK_Unrecoverable) &&
@ -2032,7 +2032,7 @@ void CodeGenFunction::EmitCheck(llvm::Value *Checked, StringRef CheckName,
(NeedsAbortSuffix? "_abort" : "")).str();
llvm::Value *Fn =
CGM.CreateRuntimeFunction(FnType, FunctionName,
llvm::Attributes::get(getLLVMContext(), B));
llvm::Attribute::get(getLLVMContext(), B));
llvm::CallInst *HandlerCall = Builder.CreateCall(Fn, Args);
if (Recover) {
Builder.CreateBr(Cont);

View File

@ -1713,7 +1713,7 @@ static llvm::Constant *createARCRuntimeFunction(CodeGenModule &CGM,
f->setLinkage(llvm::Function::ExternalWeakLinkage);
// set nonlazybind attribute for these APIs for performance.
if (fnName == "objc_retain" || fnName == "objc_release")
f->addFnAttr(llvm::Attributes::NonLazyBind);
f->addFnAttr(llvm::Attribute::NonLazyBind);
}
return fn;

View File

@ -64,8 +64,8 @@ private:
return CGM.CreateRuntimeFunction(llvm::FunctionType::get(ObjectPtrTy,
params, true),
"objc_msgSend",
llvm::Attributes::get(CGM.getLLVMContext(),
llvm::Attributes::NonLazyBind));
llvm::Attribute::get(CGM.getLLVMContext(),
llvm::Attribute::NonLazyBind));
}
/// void objc_msgSend_stret (id, SEL, ...)
@ -582,8 +582,8 @@ public:
return CGM.CreateRuntimeFunction(llvm::FunctionType::get(CGM.Int32Ty,
params, false),
"_setjmp",
llvm::Attributes::get(CGM.getLLVMContext(),
llvm::Attributes::NonLazyBind));
llvm::Attribute::get(CGM.getLLVMContext(),
llvm::Attribute::NonLazyBind));
}
public:

View File

@ -1641,8 +1641,8 @@ void CodeGenFunction::EmitAsmStmt(const AsmStmt &S) {
/* IsAlignStack */ false, AsmDialect);
llvm::CallInst *Result = Builder.CreateCall(IA, Args);
Result->addAttribute(llvm::AttributeSet::FunctionIndex,
llvm::Attributes::get(getLLVMContext(),
llvm::Attributes::NoUnwind));
llvm::Attribute::get(getLLVMContext(),
llvm::Attribute::NoUnwind));
// Slap the source location of the inline asm into a !srcloc metadata on the
// call. FIXME: Handle metadata for MS-style inline asms.

View File

@ -354,7 +354,7 @@ void CodeGenFunction::StartFunction(GlobalDecl GD, QualType RetTy,
for (FunctionDecl::redecl_iterator RI = FD->redecls_begin(),
RE = FD->redecls_end(); RI != RE; ++RI)
if (RI->isInlineSpecified()) {
Fn->addFnAttr(llvm::Attributes::InlineHint);
Fn->addFnAttr(llvm::Attribute::InlineHint);
break;
}

View File

@ -563,28 +563,28 @@ void CodeGenModule::SetLLVMFunctionAttributesForDefinition(const Decl *D,
F->setHasUWTable();
if (!hasUnwindExceptions(LangOpts))
F->addFnAttr(llvm::Attributes::NoUnwind);
F->addFnAttr(llvm::Attribute::NoUnwind);
if (D->hasAttr<NakedAttr>()) {
// Naked implies noinline: we should not be inlining such functions.
F->addFnAttr(llvm::Attributes::Naked);
F->addFnAttr(llvm::Attributes::NoInline);
F->addFnAttr(llvm::Attribute::Naked);
F->addFnAttr(llvm::Attribute::NoInline);
}
if (D->hasAttr<NoInlineAttr>())
F->addFnAttr(llvm::Attributes::NoInline);
F->addFnAttr(llvm::Attribute::NoInline);
// (noinline wins over always_inline, and we can't specify both in IR)
if ((D->hasAttr<AlwaysInlineAttr>() || D->hasAttr<ForceInlineAttr>()) &&
!F->getFnAttributes().hasAttribute(llvm::Attributes::NoInline))
F->addFnAttr(llvm::Attributes::AlwaysInline);
!F->getFnAttributes().hasAttribute(llvm::Attribute::NoInline))
F->addFnAttr(llvm::Attribute::AlwaysInline);
// FIXME: Communicate hot and cold attributes to LLVM more directly.
if (D->hasAttr<ColdAttr>())
F->addFnAttr(llvm::Attributes::OptimizeForSize);
F->addFnAttr(llvm::Attribute::OptimizeForSize);
if (D->hasAttr<MinSizeAttr>())
F->addFnAttr(llvm::Attributes::MinSize);
F->addFnAttr(llvm::Attribute::MinSize);
if (isa<CXXConstructorDecl>(D) || isa<CXXDestructorDecl>(D))
F->setUnnamedAddr(true);
@ -594,15 +594,15 @@ void CodeGenModule::SetLLVMFunctionAttributesForDefinition(const Decl *D,
F->setUnnamedAddr(true);
if (LangOpts.getStackProtector() == LangOptions::SSPOn)
F->addFnAttr(llvm::Attributes::StackProtect);
F->addFnAttr(llvm::Attribute::StackProtect);
else if (LangOpts.getStackProtector() == LangOptions::SSPReq)
F->addFnAttr(llvm::Attributes::StackProtectReq);
F->addFnAttr(llvm::Attribute::StackProtectReq);
if (LangOpts.SanitizeAddress) {
// When AddressSanitizer is enabled, set AddressSafety attribute
// unless __attribute__((no_address_safety_analysis)) is used.
if (!D->hasAttr<NoAddressSafetyAnalysisAttr>())
F->addFnAttr(llvm::Attributes::AddressSafety);
F->addFnAttr(llvm::Attribute::AddressSafety);
}
unsigned alignment = D->getMaxAlignment() / Context.getCharWidth();
@ -1106,7 +1106,7 @@ llvm::Constant *
CodeGenModule::GetOrCreateLLVMFunction(StringRef MangledName,
llvm::Type *Ty,
GlobalDecl D, bool ForVTable,
llvm::Attributes ExtraAttrs) {
llvm::Attribute ExtraAttrs) {
// Lookup the entry, lazily creating it if necessary.
llvm::GlobalValue *Entry = GetGlobalValue(MangledName);
if (Entry) {
@ -1214,7 +1214,7 @@ llvm::Constant *CodeGenModule::GetAddrOfFunction(GlobalDecl GD,
llvm::Constant *
CodeGenModule::CreateRuntimeFunction(llvm::FunctionType *FTy,
StringRef Name,
llvm::Attributes ExtraAttrs) {
llvm::Attribute ExtraAttrs) {
return GetOrCreateLLVMFunction(Name, FTy, GlobalDecl(), /*ForVTable=*/false,
ExtraAttrs);
}
@ -1823,7 +1823,7 @@ static void replaceUsesOfNonProtoConstant(llvm::Constant *old,
llvm::AttributeSet oldAttrs = callSite.getAttributes();
// Collect any return attributes from the call.
llvm::Attributes returnAttrs = oldAttrs.getRetAttributes();
llvm::Attribute returnAttrs = oldAttrs.getRetAttributes();
if (returnAttrs.hasAttributes())
newAttrs.push_back(llvm::AttributeWithIndex::get(
llvm::AttributeSet::ReturnIndex, returnAttrs));
@ -1844,14 +1844,14 @@ static void replaceUsesOfNonProtoConstant(llvm::Constant *old,
}
// Add any parameter attributes.
llvm::Attributes pAttrs = oldAttrs.getParamAttributes(argNo + 1);
llvm::Attribute pAttrs = oldAttrs.getParamAttributes(argNo + 1);
if (pAttrs.hasAttributes())
newAttrs.push_back(llvm::AttributeWithIndex::get(argNo + 1, pAttrs));
}
if (dontTransform)
continue;
llvm::Attributes fnAttrs = oldAttrs.getFnAttributes();
llvm::Attribute fnAttrs = oldAttrs.getFnAttributes();
if (fnAttrs.hasAttributes())
newAttrs.push_back(llvm::
AttributeWithIndex::get(llvm::AttributeSet::FunctionIndex,

View File

@ -711,8 +711,8 @@ public:
/// type and name.
llvm::Constant *CreateRuntimeFunction(llvm::FunctionType *Ty,
StringRef Name,
llvm::Attributes ExtraAttrs =
llvm::Attributes());
llvm::Attribute ExtraAttrs =
llvm::Attribute());
/// CreateRuntimeVariable - Create a new runtime global variable with the
/// specified type and name.
llvm::Constant *CreateRuntimeVariable(llvm::Type *Ty,
@ -890,8 +890,8 @@ private:
llvm::Type *Ty,
GlobalDecl D,
bool ForVTable,
llvm::Attributes ExtraAttrs =
llvm::Attributes());
llvm::Attribute ExtraAttrs =
llvm::Attribute());
llvm::Constant *GetOrCreateLLVMGlobal(StringRef MangledName,
llvm::PointerType *PTy,
const VarDecl *D,

View File

@ -952,8 +952,8 @@ static llvm::Constant *getGuardAcquireFn(CodeGenModule &CGM,
llvm::FunctionType::get(CGM.getTypes().ConvertType(CGM.getContext().IntTy),
GuardPtrTy, /*isVarArg=*/false);
return CGM.CreateRuntimeFunction(FTy, "__cxa_guard_acquire",
llvm::Attributes::get(CGM.getLLVMContext(),
llvm::Attributes::NoUnwind));
llvm::Attribute::get(CGM.getLLVMContext(),
llvm::Attribute::NoUnwind));
}
static llvm::Constant *getGuardReleaseFn(CodeGenModule &CGM,
@ -962,8 +962,8 @@ static llvm::Constant *getGuardReleaseFn(CodeGenModule &CGM,
llvm::FunctionType *FTy =
llvm::FunctionType::get(CGM.VoidTy, GuardPtrTy, /*isVarArg=*/false);
return CGM.CreateRuntimeFunction(FTy, "__cxa_guard_release",
llvm::Attributes::get(CGM.getLLVMContext(),
llvm::Attributes::NoUnwind));
llvm::Attribute::get(CGM.getLLVMContext(),
llvm::Attribute::NoUnwind));
}
static llvm::Constant *getGuardAbortFn(CodeGenModule &CGM,
@ -972,8 +972,8 @@ static llvm::Constant *getGuardAbortFn(CodeGenModule &CGM,
llvm::FunctionType *FTy =
llvm::FunctionType::get(CGM.VoidTy, GuardPtrTy, /*isVarArg=*/false);
return CGM.CreateRuntimeFunction(FTy, "__cxa_guard_abort",
llvm::Attributes::get(CGM.getLLVMContext(),
llvm::Attributes::NoUnwind));
llvm::Attribute::get(CGM.getLLVMContext(),
llvm::Attribute::NoUnwind));
}
namespace {

View File

@ -1020,7 +1020,7 @@ void X86_32TargetCodeGenInfo::SetTargetAttributes(const Decl *D,
llvm::AttrBuilder B;
B.addStackAlignmentAttr(16);
Fn->addAttribute(llvm::AttributeSet::FunctionIndex,
llvm::Attributes::get(CGM.getLLVMContext(), B));
llvm::Attribute::get(CGM.getLLVMContext(), B));
}
}
}
@ -3644,7 +3644,7 @@ SetTargetAttributes(const Decl *D, llvm::GlobalValue *GV,
// OpenCL __kernel functions get a kernel calling convention
F->setCallingConv(llvm::CallingConv::PTX_Kernel);
// And kernel functions are not subject to inlining
F->addFnAttr(llvm::Attributes::NoInline);
F->addFnAttr(llvm::Attribute::NoInline);
}
}
@ -3760,7 +3760,7 @@ void MBlazeTargetCodeGenInfo::SetTargetAttributes(const Decl *D,
F->setCallingConv(CC);
// Step 2: Add attributes goodness.
F->addFnAttr(llvm::Attributes::NoInline);
F->addFnAttr(llvm::Attribute::NoInline);
}
// Step 3: Emit _interrupt_handler alias.
@ -3798,7 +3798,7 @@ void MSP430TargetCodeGenInfo::SetTargetAttributes(const Decl *D,
F->setCallingConv(llvm::CallingConv::MSP430_INTR);
// Step 2: Add attributes goodness.
F->addFnAttr(llvm::Attributes::NoInline);
F->addFnAttr(llvm::Attribute::NoInline);
// Step 3: Emit ISR vector alias.
unsigned Num = attr->getNumber() / 2;
@ -4155,7 +4155,7 @@ void TCETargetCodeGenInfo::SetTargetAttributes(const Decl *D,
if (M.getLangOpts().OpenCL) {
if (FD->hasAttr<OpenCLKernelAttr>()) {
// OpenCL C Kernel functions are not subject to inlining
F->addFnAttr(llvm::Attributes::NoInline);
F->addFnAttr(llvm::Attribute::NoInline);
if (FD->hasAttr<ReqdWorkGroupSizeAttr>()) {