Skip to content

Commit

Permalink
Add comment
Browse files Browse the repository at this point in the history
  • Loading branch information
k-sareen authored Aug 28, 2024
1 parent 47d8422 commit e56a18e
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/util/heap/monotonepageresource.rs
Original file line number Diff line number Diff line change
Expand Up @@ -350,6 +350,8 @@ impl<VM: VMBinding> MonotonePageResource<VM> {
} else {
let start = self.discontiguous_start;
self.discontiguous_start = self.pr.vm_map().get_next_contiguous_region(start);
// If the current cursor is within the current discontiguous region (i.e. chunk),
// then return the size till the cursor
let size = if self.pr.cursor().chunk_index() == start.chunk_index() {
self.pr.cursor() - start
} else {
Expand Down

0 comments on commit e56a18e

Please sign in to comment.