Skip to content

Commit

Permalink
handle instruction pointer correctly for noop
Browse files Browse the repository at this point in the history
  • Loading branch information
martyall committed Jan 17, 2025
1 parent a34723f commit 3cbaf3c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion o1vm/src/interpreters/mips/interpreter.rs
Original file line number Diff line number Diff line change
Expand Up @@ -996,7 +996,8 @@ pub fn interpret_noop<Env: InterpreterEnv>(env: &mut Env) {
env.range_check8(&opcode, 6);
env.assert_is_zero(opcode);
let next_instruction_pointer = env.get_next_instruction_pointer();
env.set_instruction_pointer(next_instruction_pointer);
env.set_instruction_pointer(next_instruction_pointer.clone());
env.set_next_instruction_pointer(next_instruction_pointer + Env::constant(4u32));
}

pub fn interpret_rtype<Env: InterpreterEnv>(env: &mut Env, instr: RTypeInstruction) {
Expand Down

0 comments on commit 3cbaf3c

Please sign in to comment.