There was an error while loading. Please reload this page.
1 parent a29385a commit 79cc977Copy full SHA for 79cc977
1 file changed
src/gem.rs
@@ -32,6 +32,12 @@ impl GemPool {
32
Ok(())
33
}
34
35
+ pub fn mmap(&mut self, handle: u32) -> Option<&mut [u8]> {
36
+ self.pool
37
+ .get_mut(&handle)
38
+ .map(|dvec| unsafe { core::slice::from_raw_parts_mut(dvec.as_ptr(), dvec.len()) })
39
+ }
40
+
41
pub fn sync(&mut self, args: &mut RknpuMemSync) {}
42
43
pub fn destroy(&mut self, handle: u32) {
0 commit comments