Home
last modified time | relevance | path

Searched refs:write_head (Results 1 – 2 of 2) sorted by relevance

/system/extras/simpleperf/
DRecordReadThread.cpp40 size_t write_head = write_head_.load(std::memory_order_relaxed); in GetFreeSize() local
43 if (write_head <= write_tail) { in GetFreeSize()
44 return write_tail - write_head; in GetFreeSize()
46 return buffer_size_ - write_head + write_tail; in GetFreeSize()
50 size_t write_head = write_head_.load(std::memory_order_relaxed); in AllocWriteSpace() local
54 if (write_head < write_tail) { in AllocWriteSpace()
55 if (write_head + record_size > write_tail) { in AllocWriteSpace()
58 } else if (write_head + record_size > buffer_size_) { in AllocWriteSpace()
63 if (buffer_size_ - write_head >= sizeof(perf_event_header)) { in AllocWriteSpace()
66 memset(buffer_.get() + write_head, 0, sizeof(perf_event_header)); in AllocWriteSpace()
[all …]
Devent_fd.cpp243 uint64_t write_head = mmap_metadata_page_->data_head; in GetAvailableMmapDataSize() local
247 if (write_head <= read_head) { in GetAvailableMmapDataSize()
254 return write_head - read_head; in GetAvailableMmapDataSize()
295 uint64_t write_head = mmap_metadata_page_->aux_head; in GetAvailableAuxData() local
297 if (write_head <= read_head) { in GetAvailableAuxData()
304 size_t data_size = write_head - read_head; in GetAvailableAuxData()