summaryrefslogtreecommitdiff
path: root/tb/sim/modeswitch.py
diff options
context:
space:
mode:
authorAlejandro Soto <alejandro@34project.org>2022-11-16 16:46:52 -0600
committerAlejandro Soto <alejandro@34project.org>2022-11-16 17:55:27 -0600
commit683352ce030923bdef3cf4fe90d6cb73f4f74529 (patch)
tree09bfdff34626fe90a10d93df2c293f7d87763e44 /tb/sim/modeswitch.py
parent14a3611e492d2f213e81c9053bf613a5d8ad30a6 (diff)
Implement psr read/write logic
Diffstat (limited to 'tb/sim/modeswitch.py')
-rw-r--r--tb/sim/modeswitch.py11
1 files changed, 9 insertions, 2 deletions
diff --git a/tb/sim/modeswitch.py b/tb/sim/modeswitch.py
index 6919f2e..6c8cd79 100644
--- a/tb/sim/modeswitch.py
+++ b/tb/sim/modeswitch.py
@@ -1,3 +1,10 @@
def final():
- #TODO
- assert_reg(r0, -1)
+ assert_reg(r0, 0x0000_01d3)
+ assert_reg(r1, 0x0000_01d3)
+ assert_reg(r2, 0x0000_01d3)
+ assert_reg(r3, 0x0000_0010)
+ assert_reg(r4, 0x0000_0110)
+ assert_reg(r5, 0x4000_0110)
+ assert_reg(cpsr, 0x0000_0110)
+ assert_reg(r13_svc, 0x2000_0000)
+ assert_reg(r13_und, 0x0000_01db)