WARNING! Access to this system is limited to authorised users only.
Unauthorised users may be subject to prosecution.
Unauthorised access to this system is a criminal offence under Australian law (Federal Crimes Act 1914 Part VIA)
It is a criminal offence to:
(1) Obtain access to data without authority. -Penalty 2 years imprisonment.
(2) Damage, delete, alter or insert data without authority. -Penalty 10 years imprisonment.
User activity is monitored and recorded. Anyone using this system expressly consents to such monitoring and recording.

To protect your data, the CISO officer has suggested users to enable 2FA as soon as possible.
Currently 2.7% of users enabled 2FA.

Commit 07c4183f authored by Isaac Oscar Gariano's avatar Isaac Oscar Gariano
Browse files

Dumped unneeded VM fiels as empty hashmaps instead of null bytes

parent e9d49a43
......@@ -62,9 +62,6 @@ pub struct VM { // The comments are the offset into the struct
pub primordial: RwLock<Option<MuPrimordialThread>>, // +568
pub vm_options: VMOptions, // +624
// WARNING: It will segfault if you try to acquire a lock, after loading a dump,
// from one of the fields that aren't dumped
// ---partially serialize---
compiled_funcs: RwLock<HashMap<MuID, RwLock<CompiledFunction>>>, // +728
......@@ -104,9 +101,19 @@ unsafe impl rodal::Dump for VM {
// Dump an emepty hashmap for the compiled_exception_table
// Dump empty maps so that we can safely read and modify them once loaded
dumper.dump_object_here(&RwLock::new(rodal::EmptyHashMap::<MuID, ValueLocation>::new()));
dumper.dump_object_here(&RwLock::new(rodal::EmptyHashMap::<MuID, RwLock<MuFunctionVersion>>::new()));
dumper.dump_object_here(&RwLock::new(rodal::EmptyHashMap::<Address, ValueLocation>::new()));
// Dump an emepty hashmap for the other hashmaps
dumper.dump_object_here(&RwLock::new(HashMap::<Address, (Address, *const CompiledFunction)>::new()));
dumper.dump_object_here(&RwLock::new(rodal::EmptyHashMap::<Address, (Address, *const CompiledFunction)>::new()));
// This field is actually stored at the end of the struct, the others all have the same allignment so are not reordered
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment