aboutsummaryrefslogtreecommitdiff
path: root/debug/targets/RISC-V/spike32-2.py
diff options
context:
space:
mode:
authorTim Newsome <tim@sifive.com>2017-08-07 12:51:42 -0700
committerTim Newsome <tim@sifive.com>2017-08-28 12:16:39 -0700
commit3a44725d27f6b2c77f0ca912d792b6856fde6a17 (patch)
treee89d52105aa01d59e7d4588ef157d477f0a4335d /debug/targets/RISC-V/spike32-2.py
parentab6c2ccaec192684cf4649d5d69bd105d738d1c7 (diff)
downloadriscv-tests-3a44725d27f6b2c77f0ca912d792b6856fde6a17.zip
riscv-tests-3a44725d27f6b2c77f0ca912d792b6856fde6a17.tar.gz
riscv-tests-3a44725d27f6b2c77f0ca912d792b6856fde6a17.tar.bz2
Make the debug tests aware of multicore.
Targets now contain an array of harts. When running a regular test, one hart is selected to run the test on while the remaining harts are parked in a safe infinite loop. There's currently only one test that tests multicore behavior, but there could be more. The infrastructure should be able to support heterogeneous multicore, but I don't have a target like that to test with.
Diffstat (limited to 'debug/targets/RISC-V/spike32-2.py')
-rw-r--r--debug/targets/RISC-V/spike32-2.py11
1 files changed, 11 insertions, 0 deletions
diff --git a/debug/targets/RISC-V/spike32-2.py b/debug/targets/RISC-V/spike32-2.py
new file mode 100644
index 0000000..3f87d26
--- /dev/null
+++ b/debug/targets/RISC-V/spike32-2.py
@@ -0,0 +1,11 @@
+import targets
+import testlib
+
+import spike32
+
+class spike32_2(targets.Target):
+ harts = [spike32.spike32_hart(), spike32.spike32_hart()]
+ openocd_config_path = "spike.cfg"
+
+ def create(self):
+ return testlib.Spike(self)