1
0
forked from Rativel/BurritOS

compare mem_checker and machine

This commit is contained in:
Baptiste
2023-03-07 17:32:59 +01:00
parent d352f5dcd2
commit 1e2e537ec9
3 changed files with 25 additions and 7 deletions

View File

@@ -194,6 +194,19 @@ impl Mem_Checker{
}
pub fn compare_machine_memory(m_c: &Mem_Checker, machine: &Machine) -> bool {
for section in m_c.sections.iter() {
for i in 0..section.len {
if machine.main_memory[section.addr + i] != section.content[i] {
return false;
}
}
}
return true;
}
}