Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Heap traversal #1174

Merged
merged 36 commits into from
Aug 8, 2024
Merged
Changes from 1 commit
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
b0d297d
WIP: enumerate objects and regions
wks Jul 24, 2024
c69a68b
WIP: linear scanning metadata
wks Jul 24, 2024
a837987
Refactor iterate_meta_bits
wks Jul 29, 2024
b1b975a
Merge branch 'master' into feature/each-object
wks Jul 30, 2024
7d3f79d
Fix warning
wks Jul 30, 2024
acaf942
Benchmarks
wks Jul 31, 2024
553f210
Merge branch 'fix/bulk-metadata-visit-simple' into feature/each-object
wks Aug 1, 2024
f4a08b3
Remove ByteWordRange
wks Aug 1, 2024
a51cdc4
Fix clippy warnings
wks Aug 1, 2024
b1486e3
Formatting
wks Aug 1, 2024
ab28a79
Move iterate_meta_bits to ranges::break_bit_range
wks Aug 1, 2024
e2bafd5
Add tests and fix bugs
wks Aug 1, 2024
c3c3dfa
Just use u8 for the type of bit offset.
wks Aug 2, 2024
19a366f
Merge branch 'fix/bulk-metadata-visit-simple' into feature/each-object
wks Aug 2, 2024
3a4747c
Fix and comment
wks Aug 2, 2024
765da3b
Formatting
wks Aug 2, 2024
a73061c
Comments
wks Aug 5, 2024
5f1e99e
Merge branch 'fix/bulk-metadata-visit-simple' into feature/each-object
wks Aug 5, 2024
419655f
Minor changes
wks Aug 5, 2024
6eb3073
Mock test for heap traversal
wks Aug 5, 2024
f3c80af
Add benchmark for bitmap scanning
wks Aug 5, 2024
d994f6e
Merge branch 'master' into fix/bulk-metadata-visit-simple
wks Aug 5, 2024
323d39e
Revert criterion version update
wks Aug 6, 2024
95cd6df
Fix comments
wks Aug 6, 2024
32b4ab8
Merge branch 'fix/bulk-metadata-visit-simple' into feature/each-object
wks Aug 6, 2024
8b91a21
Support VMSpace
wks Aug 6, 2024
70e8933
Renamed to Space::enumerate_object_coarse
wks Aug 6, 2024
4f6d1bd
Revert `Region::as_range()`.
wks Aug 6, 2024
e1669d2
Merge branch 'master' into feature/each-object
wks Aug 7, 2024
38edbc9
Merge branch 'master' into feature/each-object
wks Aug 7, 2024
557e7c4
Remove the "bench" feature
wks Aug 7, 2024
ec194aa
Comments
wks Aug 7, 2024
ce3c723
Rename back to Space::enumerate_objects
wks Aug 8, 2024
81a9fab
Use vo_bit::get_object_ref_for_vo_addr
wks Aug 8, 2024
d11aa54
Update comments of MMTK::enumerate_objects
wks Aug 8, 2024
7130211
Rename remaining enumerate_objects_coarse
wks Aug 8, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Support VMSpace
wks committed Aug 6, 2024

Unverified

This commit is not signed, but one or more authors requires that any commit attributed to them is signed.
commit 8b91a21c30be63419490853f49a50e66eaf53486
8 changes: 8 additions & 0 deletions src/policy/vmspace.rs
Original file line number Diff line number Diff line change
@@ -11,6 +11,7 @@ use crate::util::heap::PageResource;
use crate::util::metadata::mark_bit::MarkState;
#[cfg(feature = "set_unlog_bits_vm_space")]
use crate::util::metadata::MetadataSpec;
use crate::util::object_enum::ObjectEnumerator;
use crate::util::opaque_pointer::*;
use crate::util::ObjectReference;
use crate::vm::{ObjectModel, VMBinding};
@@ -145,6 +146,13 @@ impl<VM: VMBinding> Space<VM> for VMSpace<VM> {
// mmapped by the runtime rather than us). So we we use SFT here.
SFT_MAP.get_checked(start).name() == self.name()
}

fn enumerate_objects(&self, enumerator: &mut dyn ObjectEnumerator) {
let external_pages = self.pr.get_external_pages();
for ep in external_pages.iter() {
enumerator.visit_address_range(ep.start..ep.end);
}
}
}

use crate::scheduler::GCWorker;