mirror of
https://github.com/RPCS3/llvm.git
synced 2025-01-05 19:29:54 +00:00
[TableGen] Remove all the static vectors named TheActualPool.
These used to hold std::unique_ptrs that managed the allocation for the various *Init object so that they would be deleted on exit. Everything is allocated in a BumpPtrAllocator name so there is no reason for these to still exist. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@304066 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
c835f01b1c
commit
f6f10854e2
@ -219,7 +219,6 @@ ProfileBitsInit(FoldingSetNodeID &ID, ArrayRef<Init *> Range) {
|
|||||||
|
|
||||||
BitsInit *BitsInit::get(ArrayRef<Init *> Range) {
|
BitsInit *BitsInit::get(ArrayRef<Init *> Range) {
|
||||||
static FoldingSet<BitsInit> ThePool;
|
static FoldingSet<BitsInit> ThePool;
|
||||||
static std::vector<BitsInit*> TheActualPool;
|
|
||||||
|
|
||||||
FoldingSetNodeID ID;
|
FoldingSetNodeID ID;
|
||||||
ProfileBitsInit(ID, Range);
|
ProfileBitsInit(ID, Range);
|
||||||
@ -234,7 +233,6 @@ BitsInit *BitsInit::get(ArrayRef<Init *> Range) {
|
|||||||
std::uninitialized_copy(Range.begin(), Range.end(),
|
std::uninitialized_copy(Range.begin(), Range.end(),
|
||||||
I->getTrailingObjects<Init *>());
|
I->getTrailingObjects<Init *>());
|
||||||
ThePool.InsertNode(I, IP);
|
ThePool.InsertNode(I, IP);
|
||||||
TheActualPool.push_back(I);
|
|
||||||
return I;
|
return I;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -456,7 +454,6 @@ static void ProfileListInit(FoldingSetNodeID &ID,
|
|||||||
|
|
||||||
ListInit *ListInit::get(ArrayRef<Init *> Range, RecTy *EltTy) {
|
ListInit *ListInit::get(ArrayRef<Init *> Range, RecTy *EltTy) {
|
||||||
static FoldingSet<ListInit> ThePool;
|
static FoldingSet<ListInit> ThePool;
|
||||||
static std::vector<ListInit*> TheActualPool;
|
|
||||||
|
|
||||||
FoldingSetNodeID ID;
|
FoldingSetNodeID ID;
|
||||||
ProfileListInit(ID, Range, EltTy);
|
ProfileListInit(ID, Range, EltTy);
|
||||||
@ -471,7 +468,6 @@ ListInit *ListInit::get(ArrayRef<Init *> Range, RecTy *EltTy) {
|
|||||||
std::uninitialized_copy(Range.begin(), Range.end(),
|
std::uninitialized_copy(Range.begin(), Range.end(),
|
||||||
I->getTrailingObjects<Init *>());
|
I->getTrailingObjects<Init *>());
|
||||||
ThePool.InsertNode(I, IP);
|
ThePool.InsertNode(I, IP);
|
||||||
TheActualPool.push_back(I);
|
|
||||||
return I;
|
return I;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -606,7 +602,6 @@ ProfileUnOpInit(FoldingSetNodeID &ID, unsigned Opcode, Init *Op, RecTy *Type) {
|
|||||||
|
|
||||||
UnOpInit *UnOpInit::get(UnaryOp Opc, Init *LHS, RecTy *Type) {
|
UnOpInit *UnOpInit::get(UnaryOp Opc, Init *LHS, RecTy *Type) {
|
||||||
static FoldingSet<UnOpInit> ThePool;
|
static FoldingSet<UnOpInit> ThePool;
|
||||||
static std::vector<UnOpInit*> TheActualPool;
|
|
||||||
|
|
||||||
FoldingSetNodeID ID;
|
FoldingSetNodeID ID;
|
||||||
ProfileUnOpInit(ID, Opc, LHS, Type);
|
ProfileUnOpInit(ID, Opc, LHS, Type);
|
||||||
@ -617,7 +612,6 @@ UnOpInit *UnOpInit::get(UnaryOp Opc, Init *LHS, RecTy *Type) {
|
|||||||
|
|
||||||
UnOpInit *I = new(Allocator) UnOpInit(Opc, LHS, Type);
|
UnOpInit *I = new(Allocator) UnOpInit(Opc, LHS, Type);
|
||||||
ThePool.InsertNode(I, IP);
|
ThePool.InsertNode(I, IP);
|
||||||
TheActualPool.push_back(I);
|
|
||||||
return I;
|
return I;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -752,7 +746,6 @@ ProfileBinOpInit(FoldingSetNodeID &ID, unsigned Opcode, Init *LHS, Init *RHS,
|
|||||||
BinOpInit *BinOpInit::get(BinaryOp Opc, Init *LHS,
|
BinOpInit *BinOpInit::get(BinaryOp Opc, Init *LHS,
|
||||||
Init *RHS, RecTy *Type) {
|
Init *RHS, RecTy *Type) {
|
||||||
static FoldingSet<BinOpInit> ThePool;
|
static FoldingSet<BinOpInit> ThePool;
|
||||||
static std::vector<BinOpInit*> TheActualPool;
|
|
||||||
|
|
||||||
FoldingSetNodeID ID;
|
FoldingSetNodeID ID;
|
||||||
ProfileBinOpInit(ID, Opc, LHS, RHS, Type);
|
ProfileBinOpInit(ID, Opc, LHS, RHS, Type);
|
||||||
@ -763,7 +756,6 @@ BinOpInit *BinOpInit::get(BinaryOp Opc, Init *LHS,
|
|||||||
|
|
||||||
BinOpInit *I = new(Allocator) BinOpInit(Opc, LHS, RHS, Type);
|
BinOpInit *I = new(Allocator) BinOpInit(Opc, LHS, RHS, Type);
|
||||||
ThePool.InsertNode(I, IP);
|
ThePool.InsertNode(I, IP);
|
||||||
TheActualPool.push_back(I);
|
|
||||||
return I;
|
return I;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -910,7 +902,6 @@ ProfileTernOpInit(FoldingSetNodeID &ID, unsigned Opcode, Init *LHS, Init *MHS,
|
|||||||
TernOpInit *TernOpInit::get(TernaryOp Opc, Init *LHS, Init *MHS, Init *RHS,
|
TernOpInit *TernOpInit::get(TernaryOp Opc, Init *LHS, Init *MHS, Init *RHS,
|
||||||
RecTy *Type) {
|
RecTy *Type) {
|
||||||
static FoldingSet<TernOpInit> ThePool;
|
static FoldingSet<TernOpInit> ThePool;
|
||||||
static std::vector<TernOpInit*> TheActualPool;
|
|
||||||
|
|
||||||
FoldingSetNodeID ID;
|
FoldingSetNodeID ID;
|
||||||
ProfileTernOpInit(ID, Opc, LHS, MHS, RHS, Type);
|
ProfileTernOpInit(ID, Opc, LHS, MHS, RHS, Type);
|
||||||
@ -921,7 +912,6 @@ TernOpInit *TernOpInit::get(TernaryOp Opc, Init *LHS, Init *MHS, Init *RHS,
|
|||||||
|
|
||||||
TernOpInit *I = new(Allocator) TernOpInit(Opc, LHS, MHS, RHS, Type);
|
TernOpInit *I = new(Allocator) TernOpInit(Opc, LHS, MHS, RHS, Type);
|
||||||
ThePool.InsertNode(I, IP);
|
ThePool.InsertNode(I, IP);
|
||||||
TheActualPool.push_back(I);
|
|
||||||
return I;
|
return I;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1503,7 +1493,6 @@ DagInit *
|
|||||||
DagInit::get(Init *V, StringInit *VN, ArrayRef<Init *> ArgRange,
|
DagInit::get(Init *V, StringInit *VN, ArrayRef<Init *> ArgRange,
|
||||||
ArrayRef<StringInit *> NameRange) {
|
ArrayRef<StringInit *> NameRange) {
|
||||||
static FoldingSet<DagInit> ThePool;
|
static FoldingSet<DagInit> ThePool;
|
||||||
static std::vector<DagInit*> TheActualPool;
|
|
||||||
|
|
||||||
FoldingSetNodeID ID;
|
FoldingSetNodeID ID;
|
||||||
ProfileDagInit(ID, V, VN, ArgRange, NameRange);
|
ProfileDagInit(ID, V, VN, ArgRange, NameRange);
|
||||||
@ -1514,7 +1503,6 @@ DagInit::get(Init *V, StringInit *VN, ArrayRef<Init *> ArgRange,
|
|||||||
|
|
||||||
DagInit *I = new(Allocator) DagInit(V, VN, ArgRange, NameRange);
|
DagInit *I = new(Allocator) DagInit(V, VN, ArgRange, NameRange);
|
||||||
ThePool.InsertNode(I, IP);
|
ThePool.InsertNode(I, IP);
|
||||||
TheActualPool.push_back(I);
|
|
||||||
return I;
|
return I;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user