calling mem_checker in main
This commit is contained in:
@ -155,7 +155,7 @@ impl Machine {
|
||||
/// - **machine** which contains a table of instructions
|
||||
pub fn run(machine : Machine){
|
||||
let mut m = machine;
|
||||
loop{
|
||||
for i in 0..MEM_SIZE{
|
||||
Machine::one_instruction(&mut m);
|
||||
}
|
||||
}
|
||||
@ -190,7 +190,8 @@ impl Machine {
|
||||
|
||||
let val = u64::from_le_bytes(val);
|
||||
let inst : Instruction = decode(val);
|
||||
|
||||
print!("executing instruction {}\n", val);
|
||||
print!("executing instruction {}\n", inst.opcode);
|
||||
|
||||
match inst.opcode {
|
||||
RISCV_LUI => {
|
||||
|
Reference in New Issue
Block a user