diff --git a/sim/rtlsim/main.cpp b/sim/rtlsim/main.cpp index ecedde81f..ea528ec19 100644 --- a/sim/rtlsim/main.cpp +++ b/sim/rtlsim/main.cpp @@ -100,8 +100,5 @@ int main(int argc, char **argv) { // read exitcode from @MPM.1 ram.read(&exitcode, (IO_MPM_ADDR + 8), 4); - if (riscv_test) { - return (1 - exitcode); - } - return exitcode; + return (riscv_test ? 13 - exitcode : exitcode); } diff --git a/sim/simx/main.cpp b/sim/simx/main.cpp index 25e685c7f..bcb9e4272 100644 --- a/sim/simx/main.cpp +++ b/sim/simx/main.cpp @@ -125,8 +125,5 @@ int main(int argc, char **argv) { ram.read(&exitcode, (IO_MPM_ADDR + 8), 4); } - if (riscv_test) { - return (13 - exitcode); // temporary fix for riscv vector tests - } - return exitcode; + return (riscv_test ? 13 - exitcode : exitcode); }