Skip to content

Commit

Permalink
fix Makefile problem with jal and jalr tests
Browse files Browse the repository at this point in the history
  • Loading branch information
martyall committed Jan 7, 2025
1 parent 849d9ae commit a7f71e2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ ${O1VM_MIPS_SOURCE_DIR}/%.asm: ${OPTIMISM_MIPS_SOURCE_DIR}/%.asm
@echo "Transforming $< to $@, making it compatible for o1vm"
@sed \
-e '/\.balign 4/d' \
-e '/\.set\s*noreorder/d' \
-e 's/^\s*\.set\s*noreorder/.set noreorder/' \
-e '/\.ent\s*test/d' \
-e '/\.end test/d' \
-e 's/\.section .test, "x"/.section .text/' \
Expand Down
4 changes: 3 additions & 1 deletion o1vm/tests/test_mips_elf.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ struct MipsTest {
// currently excluding any oracle based tests and a select group of tests that are failing
fn is_test_excluded(bin_file: &Path) -> bool {
let file_name = bin_file.file_name().unwrap().to_str().unwrap();
let untested_programs = ["exit_group", "jal", "mul", "jalr"];
let untested_programs = ["exit_group", "mul"];
file_name.starts_with("oracle") || untested_programs.contains(&file_name)
}

Expand All @@ -40,13 +40,15 @@ impl MipsTest {
}

fn run(&self) -> Result<(), String> {
println!("Running test: {:?}", self.bin_file);
let mut state = self.parse_state();
let halt_address = 0xa7ef00d0_u32;
state.registers[31] = halt_address;

let start = cannon::Start::create(state.step as usize);
let configuration = VmConfiguration {
halt_address: Some(halt_address),
stop_at: cannon::StepFrequency::Exactly(1000),
..Default::default()
};

Expand Down

0 comments on commit a7f71e2

Please sign in to comment.