diff options
-rw-r--r-- | include/llvm/Attributes.h | 29 | ||||
-rw-r--r-- | lib/AsmParser/LLParser.cpp | 2 | ||||
-rw-r--r-- | lib/VMCore/Attributes.cpp | 83 |
3 files changed, 1 insertions, 113 deletions
diff --git a/include/llvm/Attributes.h b/include/llvm/Attributes.h index 00eb325cac..11c043765c 100644 --- a/include/llvm/Attributes.h +++ b/include/llvm/Attributes.h @@ -212,35 +212,6 @@ public: void addStackAlignmentAttr(unsigned Align); void removeAttributes(const Attributes &A); - - void removeAddressSafetyAttr(); - void removeAlwaysInlineAttr(); - void removeByValAttr(); - void removeInlineHintAttr(); - void removeInRegAttr(); - void removeNakedAttr(); - void removeNestAttr(); - void removeNoAliasAttr(); - void removeNoCaptureAttr(); - void removeNoImplicitFloatAttr(); - void removeNoInlineAttr(); - void removeNonLazyBindAttr(); - void removeNoRedZoneAttr(); - void removeNoReturnAttr(); - void removeNoUnwindAttr(); - void removeOptimizeForSizeAttr(); - void removeReadNoneAttr(); - void removeReadOnlyAttr(); - void removeReturnsTwiceAttr(); - void removeSExtAttr(); - void removeStackProtectAttr(); - void removeStackProtectReqAttr(); - void removeStructRetAttr(); - void removeUWTableAttr(); - void removeZExtAttr(); - - void removeAlignmentAttr(); - void removeStackAlignmentAttr(); }; /// get - Return a uniquified Attributes object. This takes the uniquified diff --git a/lib/AsmParser/LLParser.cpp b/lib/AsmParser/LLParser.cpp index 76ac0f7b4a..86bc7aced1 100644 --- a/lib/AsmParser/LLParser.cpp +++ b/lib/AsmParser/LLParser.cpp @@ -2757,7 +2757,7 @@ bool LLParser::ParseFunctionHeader(Function *&Fn, bool isDefine) { // If the alignment was parsed as an attribute, move to the alignment field. if (FuncAttrs.hasAlignmentAttr()) { Alignment = FuncAttrs.getAlignment(); - FuncAttrs.removeAlignmentAttr(); + FuncAttrs.removeAttribute(Attributes::Alignment); } // Okay, if we got here, the function is syntactically valid. Convert types diff --git a/lib/VMCore/Attributes.cpp b/lib/VMCore/Attributes.cpp index 6e689736f3..f6906d72b7 100644 --- a/lib/VMCore/Attributes.cpp +++ b/lib/VMCore/Attributes.cpp @@ -236,89 +236,6 @@ void Attributes::Builder::removeAttributes(const Attributes &A) { Bits &= ~A.Raw(); } -void Attributes::Builder::removeAddressSafetyAttr() { - Bits &= ~Attribute::AddressSafety_i; -} -void Attributes::Builder::removeAlwaysInlineAttr() { - Bits &= ~Attribute::AlwaysInline_i; -} -void Attributes::Builder::removeByValAttr() { - Bits &= ~Attribute::ByVal_i; -} -void Attributes::Builder::removeInlineHintAttr() { - Bits &= ~Attribute::InlineHint_i; -} -void Attributes::Builder::removeInRegAttr() { - Bits &= ~Attribute::InReg_i; -} -void Attributes::Builder::removeNakedAttr() { - Bits &= ~Attribute::Naked_i; -} -void Attributes::Builder::removeNestAttr() { - Bits &= ~Attribute::Nest_i; -} -void Attributes::Builder::removeNoAliasAttr() { - Bits &= ~Attribute::NoAlias_i; -} -void Attributes::Builder::removeNoCaptureAttr() { - Bits &= ~Attribute::NoCapture_i; -} -void Attributes::Builder::removeNoImplicitFloatAttr() { - Bits &= ~Attribute::NoImplicitFloat_i; -} -void Attributes::Builder::removeNoInlineAttr() { - Bits &= ~Attribute::NoInline_i; -} -void Attributes::Builder::removeNonLazyBindAttr() { - Bits &= ~Attribute::NonLazyBind_i; -} -void Attributes::Builder::removeNoRedZoneAttr() { - Bits &= ~Attribute::NoRedZone_i; -} -void Attributes::Builder::removeNoReturnAttr() { - Bits &= ~Attribute::NoReturn_i; -} -void Attributes::Builder::removeNoUnwindAttr() { - Bits &= ~Attribute::NoUnwind_i; -} -void Attributes::Builder::removeOptimizeForSizeAttr() { - Bits &= ~Attribute::OptimizeForSize_i; -} -void Attributes::Builder::removeReadNoneAttr() { - Bits &= ~Attribute::ReadNone_i; -} -void Attributes::Builder::removeReadOnlyAttr() { - Bits &= ~Attribute::ReadOnly_i; -} -void Attributes::Builder::removeReturnsTwiceAttr() { - Bits &= ~Attribute::ReturnsTwice_i; -} -void Attributes::Builder::removeSExtAttr() { - Bits &= ~Attribute::SExt_i; -} -void Attributes::Builder::removeStackProtectAttr() { - Bits &= ~Attribute::StackProtect_i; -} -void Attributes::Builder::removeStackProtectReqAttr() { - Bits &= ~Attribute::StackProtectReq_i; -} -void Attributes::Builder::removeStructRetAttr() { - Bits &= ~Attribute::StructRet_i; -} -void Attributes::Builder::removeUWTableAttr() { - Bits &= ~Attribute::UWTable_i; -} -void Attributes::Builder::removeZExtAttr() { - Bits &= ~Attribute::ZExt_i; -} - -void Attributes::Builder::removeAlignmentAttr() { - Bits &= ~Attribute::Alignment_i; -} -void Attributes::Builder::removeStackAlignmentAttr() { - Bits &= ~Attribute::StackAlignment_i; -} - bool Attributes::Builder::hasAttributes() const { return Bits != 0; } |