summaryrefslogtreecommitdiff
path: root/include/llvm/IR/Attributes.h
diff options
context:
space:
mode:
authorBill Wendling <isanbard@gmail.com>2013-01-29 01:43:29 +0000
committerBill Wendling <isanbard@gmail.com>2013-01-29 01:43:29 +0000
commit8232ece5c1e57efe54342fb35610497d50bf894f (patch)
tree0b4d9d6fe602f90af2b756e15d2274ba7b89fb51 /include/llvm/IR/Attributes.h
parent8fbc0c296ef067150f3228e389ae04cf7b3b1992 (diff)
downloadllvm-8232ece5c1e57efe54342fb35610497d50bf894f.tar.gz
llvm-8232ece5c1e57efe54342fb35610497d50bf894f.tar.bz2
llvm-8232ece5c1e57efe54342fb35610497d50bf894f.tar.xz
Use an AttrBuilder to generate the correct AttributeSet.
We no longer accept an encoded integer as representing all of the attributes. Convert this via the AttrBuilder class into an AttributeSet with the correct representation (an AttributeSetImpl that holds a list of Attribute objects). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173750 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/IR/Attributes.h')
-rw-r--r--include/llvm/IR/Attributes.h11
1 files changed, 6 insertions, 5 deletions
diff --git a/include/llvm/IR/Attributes.h b/include/llvm/IR/Attributes.h
index ba46d205ca..1aa733efbf 100644
--- a/include/llvm/IR/Attributes.h
+++ b/include/llvm/IR/Attributes.h
@@ -461,11 +461,12 @@ Attribute typeIncompatible(Type *Ty);
/// is a breaking change to bitcode compatibility.
uint64_t encodeLLVMAttributesForBitcode(AttributeSet Attrs, unsigned Index);
-/// \brief This returns an attribute bitset containing the LLVM attributes that
-/// have been decoded from the given integer. This function must stay in sync
-/// with 'encodeLLVMAttributesForBitcode'.
-Attribute decodeLLVMAttributesForBitcode(LLVMContext &C,
- uint64_t EncodedAttrs);
+/// \brief This fills an AttrBuilder object with the LLVM attributes that have
+/// been decoded from the given integer. This function must stay in sync with
+/// 'encodeLLVMAttributesForBitcode'.
+/// N.B. This should be used only by the bitcode reader!
+void decodeLLVMAttributesForBitcode(LLVMContext &C, AttrBuilder &B,
+ uint64_t EncodedAttrs);
} // end AttributeFuncs namespace