riscv: run tool support for spike

issue #1880
This commit is contained in:
Sebastian Sumpf
2016-02-11 11:42:00 +01:00
committed by Christian Helmuth
parent 8c6e3c6251
commit ac70dfd9fe
4 changed files with 57 additions and 1 deletions

29
tool/run/log/spike Normal file
View File

@@ -0,0 +1,29 @@
source [genode_dir]/tool/run/log.inc
source [genode_dir]/tool/run/spike.inc
proc run_log { wait_for_re timeout_value } {
global spike_spawn_id
global output_spawn_id
set timeout 210
set kernel_msg [run_boot_string]
set output_spawn_id $spike_spawn_id
expect {
-i $output_spawn_id $kernel_msg { }
eof {
puts stderr "Aborting, received EOF"
return false
}
timeout {
puts stderr "Boot process timed out"
close
return false
}
}
wait_for_output $wait_for_re $timeout_value $spike_spawn_id
return true
}