MCPcopy Create free account
hub / github.com/apache/impala / SetReadBufferBlockStatus

Method SetReadBufferBlockStatus

be/src/runtime/io/disk-file.h:441–450  ·  view source on GitHub ↗

Helper function to set the status of a memory block. Caller should hold the physical_file_lock_. If the caller holds the lock of the read buffer block, SetStatusLocked() will be called.

Source from the content-addressed store, hash-verified

439 // If the caller holds the lock of the read buffer block, SetStatusLocked() will be
440 // called.
441 void SetReadBufferBlockStatus(MemBlock* read_buffer_block, MemBlockStatus status,
442 const boost::shared_lock<boost::shared_mutex>& file_lock,
443 const std::unique_lock<SpinLock>* block_lock = nullptr) {
444 DCheckMemBlock(file_lock, read_buffer_block);
445 if (block_lock == nullptr) {
446 read_buffer_block->SetStatus(status);
447 } else {
448 read_buffer_block->SetStatusLocked(*block_lock, status);
449 }
450 }
451
452 // Helper function to check the status of a read buffer block.
453 // Caller should hold the physical_file_lock_.

Callers 2

DoFetchMethod · 0.80

Calls 2

SetStatusMethod · 0.45
SetStatusLockedMethod · 0.45

Tested by

no test coverage detected