Lines Matching refs:rosalloc

51     size_t ByteSize(RosAlloc* rosalloc) const EXCLUSIVE_LOCKS_REQUIRED(rosalloc->lock_) {  in ByteSize()  argument
53 size_t pm_idx = rosalloc->ToPageMapIndex(fpr_base); in ByteSize()
54 size_t byte_size = rosalloc->free_page_run_size_map_[pm_idx]; in ByteSize()
59 void SetByteSize(RosAlloc* rosalloc, size_t byte_size) in SetByteSize() argument
60 EXCLUSIVE_LOCKS_REQUIRED(rosalloc->lock_) { in SetByteSize()
63 size_t pm_idx = rosalloc->ToPageMapIndex(fpr_base); in SetByteSize()
64 rosalloc->free_page_run_size_map_[pm_idx] = byte_size; in SetByteSize()
69 void* End(RosAlloc* rosalloc) EXCLUSIVE_LOCKS_REQUIRED(rosalloc->lock_) { in End() argument
71 byte* end = fpr_base + ByteSize(rosalloc); in End()
74 bool IsLargerThanPageReleaseThreshold(RosAlloc* rosalloc) in IsLargerThanPageReleaseThreshold() argument
75 EXCLUSIVE_LOCKS_REQUIRED(rosalloc->lock_) { in IsLargerThanPageReleaseThreshold()
76 return ByteSize(rosalloc) >= rosalloc->page_release_size_threshold_; in IsLargerThanPageReleaseThreshold()
78 bool IsAtEndOfSpace(RosAlloc* rosalloc) in IsAtEndOfSpace() argument
79 EXCLUSIVE_LOCKS_REQUIRED(rosalloc->lock_) { in IsAtEndOfSpace()
80 …return reinterpret_cast<byte*>(this) + ByteSize(rosalloc) == rosalloc->base_ + rosalloc->footprint… in IsAtEndOfSpace()
82 bool ShouldReleasePages(RosAlloc* rosalloc) EXCLUSIVE_LOCKS_REQUIRED(rosalloc->lock_) { in ShouldReleasePages() argument
83 switch (rosalloc->page_release_mode_) { in ShouldReleasePages()
87 return IsAtEndOfSpace(rosalloc); in ShouldReleasePages()
89 return IsLargerThanPageReleaseThreshold(rosalloc); in ShouldReleasePages()
91 return IsLargerThanPageReleaseThreshold(rosalloc) && IsAtEndOfSpace(rosalloc); in ShouldReleasePages()
99 void ReleasePages(RosAlloc* rosalloc) EXCLUSIVE_LOCKS_REQUIRED(rosalloc->lock_) { in ReleasePages() argument
101 size_t byte_size = ByteSize(rosalloc); in ReleasePages()
103 if (ShouldReleasePages(rosalloc)) { in ReleasePages()
104 rosalloc->ReleasePageRange(start, start + byte_size); in ReleasePages()
248 void Verify(Thread* self, RosAlloc* rosalloc)