From 9106f73246168fb30d26fb14085c0b3d81fcd350 Mon Sep 17 00:00:00 2001 From: Reed Kotler Date: Wed, 13 Mar 2013 20:20:08 +0000 Subject: Add some additonal attribute helper functions. Test will be on follow up putback to clang for mips16. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@176968 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/llvm/IR/Attributes.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'include/llvm/IR/Attributes.h') diff --git a/include/llvm/IR/Attributes.h b/include/llvm/IR/Attributes.h index 30c0965..ddb8ea4 100644 --- a/include/llvm/IR/Attributes.h +++ b/include/llvm/IR/Attributes.h @@ -247,6 +247,11 @@ public: AttributeSet addAttribute(LLVMContext &C, unsigned Idx, Attribute::AttrKind Attr) const; + /// \brief Add an attribute to the attribute set at the given index. Since + /// attribute sets are immutable, this returns a new set. + AttributeSet addAttribute(LLVMContext &C, unsigned Idx, + StringRef Kind) const; + /// \brief Add attributes to the attribute set at the given index. Since /// attribute sets are immutable, this returns a new set. AttributeSet addAttributes(LLVMContext &C, unsigned Idx, -- cgit v1.1 From 72f0cdea4160ec3a5f5123831a57f96d3a95456c Mon Sep 17 00:00:00 2001 From: Benjamin Kramer Date: Mon, 18 Mar 2013 12:14:30 +0000 Subject: Remove default copy ctor/assignment, makes AttributeSet trivially copyable. And enables SmallVector's pod optimizations. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@177281 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/llvm/IR/Attributes.h | 5 ----- 1 file changed, 5 deletions(-) (limited to 'include/llvm/IR/Attributes.h') diff --git a/include/llvm/IR/Attributes.h b/include/llvm/IR/Attributes.h index ddb8ea4..074b387 100644 --- a/include/llvm/IR/Attributes.h +++ b/include/llvm/IR/Attributes.h @@ -226,11 +226,6 @@ private: explicit AttributeSet(AttributeSetImpl *LI) : pImpl(LI) {} public: AttributeSet() : pImpl(0) {} - AttributeSet(const AttributeSet &P) : pImpl(P.pImpl) {} - const AttributeSet &operator=(const AttributeSet &RHS) { - pImpl = RHS.pImpl; - return *this; - } //===--------------------------------------------------------------------===// // AttributeSet Construction and Mutation -- cgit v1.1