X-Git-Url: http://demsky.eecs.uci.edu/git/?a=blobdiff_plain;f=include%2Fllvm%2FSupport%2FRecyclingAllocator.h;h=34ab874778c912bc7fba98459c5fd0f189138509;hb=84bcf93e0fd225de2217d1b712c01586a633a6d8;hp=609193ffd7624835ad1470b9c504fc99faec88a6;hpb=fbe67f85b2e14bf0b9a4c2b6306ccbcefdb8956b;p=oota-llvm.git diff --git a/include/llvm/Support/RecyclingAllocator.h b/include/llvm/Support/RecyclingAllocator.h index 609193ffd76..34ab874778c 100644 --- a/include/llvm/Support/RecyclingAllocator.h +++ b/include/llvm/Support/RecyclingAllocator.h @@ -56,4 +56,18 @@ public: } +template +inline void *operator new(size_t, + llvm::RecyclingAllocator &Allocator) { + return Allocator.Allocate(); +} + +template +inline void operator delete(void *E, + llvm::RecyclingAllocator &A) { + A.Deallocate(E); +} + #endif