projects
/
platform
/
upstream
/
llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d2e493b
)
Cleanup the AttributeSetNodes that we create.
author
Bill Wendling
<isanbard@gmail.com>
Thu, 24 Jan 2013 00:14:46 +0000
(
00:14
+0000)
committer
Bill Wendling
<isanbard@gmail.com>
Thu, 24 Jan 2013 00:14:46 +0000
(
00:14
+0000)
llvm-svn: 173311
llvm/lib/IR/LLVMContextImpl.cpp
patch
|
blob
|
history
diff --git
a/llvm/lib/IR/LLVMContextImpl.cpp
b/llvm/lib/IR/LLVMContextImpl.cpp
index
8fc9379
..
89e163f
100644
(file)
--- a/
llvm/lib/IR/LLVMContextImpl.cpp
+++ b/
llvm/lib/IR/LLVMContextImpl.cpp
@@
-109,6
+109,13
@@
LLVMContextImpl::~LLVMContextImpl() {
delete &*Elem;
}
+ // Destroy attribute node lists.
+ for (FoldingSetIterator<AttributeSetNode> I = AttrsSetNodes.begin(),
+ E = AttrsSetNodes.end(); I != E; ) {
+ FoldingSetIterator<AttributeSetNode> Elem = I++;
+ delete &*Elem;
+ }
+
// Destroy MDNodes. ~MDNode can move and remove nodes between the MDNodeSet
// and the NonUniquedMDNodes sets, so copy the values out first.
SmallVector<MDNode*, 8> MDNodes;