MCPcopy Create free account
hub / github.com/apache/impala / ~FreeBufferArena

Method ~FreeBufferArena

be/src/runtime/bufferpool/buffer-allocator.cc:561–571  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

559 metrics->AddCounter("buffer-pool.$0.num-final-scavenges", 0, arena_name)) {}
560
561BufferPool::FreeBufferArena::~FreeBufferArena() {
562 for (int i = 0; i < NumBufferSizes(); ++i) {
563 // Clear out the free lists.
564 FreeList* list = &buffer_sizes_[i].free_buffers;
565 vector<BufferHandle> buffers = list->GetBuffersToFree(list->Size());
566 parent_->system_bytes_remaining_.Add(parent_->FreeToSystem(move(buffers)));
567
568 // All pages should have been destroyed.
569 DCHECK_EQ(0, buffer_sizes_[i].clean_pages.size());
570 }
571}
572
573void BufferPool::FreeBufferArena::AddFreeBuffer(BufferHandle&& buffer) {
574 lock_guard<SpinLock> al(lock_);

Callers

nothing calls this directly

Calls 6

moveFunction · 0.85
GetBuffersToFreeMethod · 0.80
FreeToSystemMethod · 0.80
SizeMethod · 0.45
AddMethod · 0.45
sizeMethod · 0.45

Tested by

no test coverage detected