diff options
author | Nuno Lopes <nunoplopes@sapo.pt> | 2012-06-18 16:04:04 +0000 |
---|---|---|
committer | Nuno Lopes <nunoplopes@sapo.pt> | 2012-06-18 16:04:04 +0000 |
commit | fa7494306bc6fbe16cc82a67b93e762241b26777 (patch) | |
tree | bc87b64fbaa757a52d4a23c4558dcfd002d3085c /lib/VMCore/LLVMContext.cpp | |
parent | 96ef284da415cccd60cf5066929a4683dec5dd79 (diff) |
add the 'alloc' metadata node to represent the size of offset of buffers pointed to by pointers.
This metadata can be attached to any instruction returning a pointer
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@158660 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/VMCore/LLVMContext.cpp')
-rw-r--r-- | lib/VMCore/LLVMContext.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/VMCore/LLVMContext.cpp b/lib/VMCore/LLVMContext.cpp index f07f0b3939..a140543a51 100644 --- a/lib/VMCore/LLVMContext.cpp +++ b/lib/VMCore/LLVMContext.cpp @@ -53,6 +53,11 @@ LLVMContext::LLVMContext() : pImpl(new LLVMContextImpl(*this)) { unsigned RangeID = getMDKindID("range"); assert(RangeID == MD_range && "range kind id drifted"); (void)RangeID; + + // Create the 'alloc' metadata kind. + unsigned AllocID = getMDKindID("alloc"); + assert(AllocID == MD_alloc && "alloc kind id drifted"); + (void)AllocID; } LLVMContext::~LLVMContext() { delete pImpl; } |