2016-02-11 10:42:00 +00:00
|
|
|
##
|
|
|
|
# Execute scenario using spike
|
|
|
|
#
|
|
|
|
source [genode_dir]/tool/run/spike.inc
|
|
|
|
|
|
|
|
proc is_spike_available { } {
|
|
|
|
|
2017-01-02 14:29:21 +00:00
|
|
|
if {[have_spec riscv]} { return true }
|
2016-02-11 10:42:00 +00:00
|
|
|
|
|
|
|
puts stderr "skipping execution because platform is not supported by spike"
|
|
|
|
return false
|
|
|
|
}
|
|
|
|
|
|
|
|
proc run_power_on { } {
|
|
|
|
global spike_args
|
|
|
|
global spike
|
|
|
|
global spike_spawn_id
|
|
|
|
|
|
|
|
if {![is_spike_available]} { return 0 }
|
|
|
|
|
2017-08-24 14:17:54 +00:00
|
|
|
append spike_args "-m128 [pwd]/debug/bbl "
|
2016-02-11 10:42:00 +00:00
|
|
|
|
|
|
|
set spike "spike"
|
|
|
|
eval spawn $spike $spike_args
|
|
|
|
set spike_spawn_id $spawn_id
|
2017-08-07 14:30:38 +00:00
|
|
|
|
|
|
|
return true
|
2016-02-11 10:42:00 +00:00
|
|
|
}
|