summaryrefslogtreecommitdiff
path: root/p
diff options
context:
space:
mode:
authorAndrew Waterman <waterman@cs.berkeley.edu>2016-05-02 14:29:14 -0700
committerAndrew Waterman <waterman@cs.berkeley.edu>2016-05-02 14:29:14 -0700
commitb54a6f8e11f43ac6df310016723ef6eb2f7d3a33 (patch)
tree21edb00b64ec0c356d0055036f77885eeecab4e8 /p
parent3d45ca302dbf5ac22cfac8fb025c05c735c35e26 (diff)
downloadenv-b54a6f8e11f43ac6df310016723ef6eb2f7d3a33.zip
env-b54a6f8e11f43ac6df310016723ef6eb2f7d3a33.tar.gz
env-b54a6f8e11f43ac6df310016723ef6eb2f7d3a33.tar.bz2
Stop using mtohost/mfromhost registers
Diffstat (limited to 'p')
-rw-r--r--p/riscv_test.h9
1 files changed, 7 insertions, 2 deletions
diff --git a/p/riscv_test.h b/p/riscv_test.h
index 903f23f..d3e8027 100644
--- a/p/riscv_test.h
+++ b/p/riscv_test.h
@@ -114,7 +114,7 @@ handle_exception: \
/* some unhandlable exception occurred */ \
1: ori TESTNUM, TESTNUM, 1337; \
write_tohost: \
- csrw mtohost, TESTNUM; \
+ sw TESTNUM, tohost, t5; \
j write_tohost; \
reset_vector: \
RISCV_MULTICORE_DISABLE; \
@@ -175,7 +175,12 @@ reset_vector: \
#define EXTRA_DATA
-#define RVTEST_DATA_BEGIN EXTRA_DATA .align 4; .global begin_signature; begin_signature:
+#define RVTEST_DATA_BEGIN \
+ EXTRA_DATA \
+ .align 6; .global tohost; tohost: .dword 0; \
+ .align 6; .global fromhost; fromhost: .dword 0; \
+ .align 4; .global begin_signature; begin_signature:
+
#define RVTEST_DATA_END .align 4; .global end_signature; end_signature:
#endif