X-Git-Url: http://plrg.eecs.uci.edu/git/?p=folly.git;a=blobdiff_plain;f=folly%2Fexperimental%2FJemallocNodumpAllocator.cpp;h=481efd000457d5d95a4ea0a68bd16e9c779607c6;hp=77d9724b4962a4b48a1eb04faebde68d0ba11ebc;hb=7c9e64a0cf44be563abdad056e45e8268e99ee0a;hpb=4929771e2f6251bfe22cf72b5bd08905625f6d64;ds=sidebyside diff --git a/folly/experimental/JemallocNodumpAllocator.cpp b/folly/experimental/JemallocNodumpAllocator.cpp index 77d9724b..481efd00 100644 --- a/folly/experimental/JemallocNodumpAllocator.cpp +++ b/folly/experimental/JemallocNodumpAllocator.cpp @@ -29,19 +29,6 @@ JemallocNodumpAllocator::JemallocNodumpAllocator(State state) { } } -JemallocNodumpAllocator::~JemallocNodumpAllocator() { -#ifdef FOLLY_JEMALLOC_NODUMP_ALLOCATOR_EXTENT - if (arena_index_ != 0) { - // Destroy the arena because the hooks are linked to us. - const auto key = folly::to("arena.", arena_index_, ".destroy"); - if (auto ret = mallctl(key.c_str(), nullptr, 0, nullptr, 0)) { - LOG(FATAL) << "Unable to destroy arena: " << errnoStr(ret); - } - LOG(INFO) << "Destroy arena: " << arena_index_; - } -#endif -} - bool JemallocNodumpAllocator::extend_and_setup_arena() { #ifdef FOLLY_JEMALLOC_NODUMP_ALLOCATOR_SUPPORTED if (mallctl == nullptr) { @@ -132,6 +119,7 @@ chunk_alloc_t* JemallocNodumpAllocator::original_alloc_ = nullptr; void* JemallocNodumpAllocator::alloc( void* chunk, #else +extent_hooks_t JemallocNodumpAllocator::extent_hooks_; extent_alloc_t* JemallocNodumpAllocator::original_alloc_ = nullptr; void* JemallocNodumpAllocator::alloc( extent_hooks_t* extent,