Track subcall read regions within read-only calls
This commit is contained in:
@@ -21,6 +21,16 @@ impl ObjectStore {
|
||||
pub fn end_read_only(&mut self, scope: usize) -> Result<Vec<ObjectRef>, VmError> {
|
||||
self.heap.end_read_only(scope)
|
||||
}
|
||||
/// Track one subcall inside the active read-only scope. Regions nest in
|
||||
/// LIFO order and do not clear the enclosing call's read dependencies.
|
||||
/// Handles returned by end_read_tracking are borrowed, never owning roots.
|
||||
pub fn begin_read_tracking(&self) -> Result<usize, VmError> {
|
||||
self.heap.begin_read_tracking()
|
||||
}
|
||||
pub fn end_read_tracking(&self, token: usize) -> Result<Vec<ObjectRef>, VmError> {
|
||||
self.heap.end_read_tracking(token)
|
||||
}
|
||||
|
||||
pub fn is_read_only(&self) -> bool {
|
||||
self.heap.is_read_only()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user