tests: Fix riscv boot exit tests

Due to this change:
https://gem5-review.googlesource.com/c/public/gem5/+/52089
full RISCV boot tests were added, which makes the "tick_exit" parameter
optional (left to 'None' if simulating a full boot). However, the
simulation function was not updated to not pass the "tick_exit"
parameter if not set. This cause an error. This patch fixes this.

Change-Id: I9c62a6a46d9334a2e9fbad2221b42a1ff4843a54
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/52644
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
This commit is contained in:
Bobby R. Bruce
2021-11-10 12:06:27 -08:00
committed by Jason Lowe-Power
parent b65b59d2d2
commit bd6da8f88d

View File

@@ -159,7 +159,10 @@ root = Root(full_system=True, system=board)
m5.instantiate()
exit_event = m5.simulate(args.tick_exit)
if args.tick_exit:
exit_event = m5.simulate(args.tick_exit)
else:
exit_event = m5.simulate()
print(
"Exiting @ tick {} because {}.".format(m5.curTick(), exit_event.getCause())
)