Skip to content

Commit

Permalink
Fix VM bug in Bgeu
Browse files Browse the repository at this point in the history
  • Loading branch information
bigspider committed Sep 19, 2024
1 parent 677c26c commit 35c0987
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion common/src/vm.rs
Original file line number Diff line number Diff line change
Expand Up @@ -497,7 +497,7 @@ impl<M: PagedMemory> Cpu<M> {
},
Op::Bgeu { rs1, rs2, imm } => {
if self.regs[rs1 as usize] >= self.regs[rs2 as usize] {
self.pc = self.pc.wrapping_add(imm as u32);
pc_inc = imm as u32;
}
},
Op::Jal { rd, imm } => {
Expand Down

0 comments on commit 35c0987

Please sign in to comment.