Commit Graph

21 Commits

Author SHA1 Message Date
Luke Wren a6558e554a Set misa.b when all of Zba, Zbb and Zbs are enabled.
(The B extension has now been ratified as this combination of extensions.)
2024-05-11 12:13:35 +01:00
Luke Wren 6db1edc675 Add dummy h3.msleep CSR to rvcpp 2024-05-11 11:02:01 +01:00
Luke Wren 194c9a9052 Implement WFI in rvcpp. The umode_wfi test still does not pass, because it relies on a bug in Hazard3 (mstatus.mie disables IRQs in U-mode as well as M-mode, but is supposed to be ignored in U-mode). 2024-04-27 20:48:30 +01:00
Luke Wren 78260e86e7 rvcpp: parameterise number of PMP regions, and set to match tb default. Fix region locking. Mask pmpaddr to 30 bits, to match Hazard3 32-bit physical address space. 2024-04-27 19:57:18 +01:00
Luke Wren ebe5a44454 rvcpp: fix up PMP address mask for all-ones pmpaddr, and raise instruction fault on instruction stradding two PMP regions, like the hardware 2024-04-27 19:34:17 +01:00
Luke Wren fce1c087d4 Add basic PMP implementation to rvcpp. Seems like the RWX vs XWR order might be transposed in both the hardware and the tests 2024-04-27 13:38:10 +01:00
Luke Wren 117c52e7b1 rvcpp: fix handling of CSR instructions which both read and write 2024-04-27 13:30:34 +01:00
Luke Wren a313493371 Add timer and soft IRQ support to rvcpp. Relevant sw_testcases now pass. 2024-03-22 00:52:01 +00:00
Luke Wren b1be56fe94 Clean up rvcpp file structure 2024-03-21 23:27:01 +00:00
Luke Wren b473575b7e rvcpp: correctly model memory access faults. relevant sw_testcases now pass.
Also, grab the special-case core RAM change from the Sv32 fork, for better performance
2024-03-21 00:33:54 +00:00
Luke Wren fd584ea24b Add Xh3bextm instructions to rvcpp, and rename xh3b test to xh3bextm 2024-03-20 23:45:30 +00:00
Luke Wren 8cbf5fceee rvcpp: fix busted RMW CSR logic, fix ordering of CSR write vs update, csr_mcycle testcase now passes 2024-03-20 01:37:04 +00:00
Luke Wren 55504fa8f3 Add support for Zba, Zbb, Zbc, Zbs, Zbkb to rvcpp. Passes tests 2024-03-20 01:06:13 +00:00
Luke Wren e1bb341876 Add support for testcase return code propagation to rvcpp.
Hook up mtvec in bitmanip testcases to exit sim when exception taken.
2024-03-20 01:05:24 +00:00
Luke Wren 32f65fb142 Expand rvcpp counter CSR implementation 2024-03-19 08:44:24 +00:00
Luke Wren a536e3baa7 rvcpp sim: add A extension and M-mode traps
(now passes a lot of the Hazard3 tests)
2023-04-01 08:21:43 +01:00
Luke Wren 26d699e18c rvcpp simulator: fix bad regnum decode for c.slli outside of x8..x15 2023-04-01 06:02:45 +01:00
Luke Wren 8f461b63b4 Fix mvsa01/mva01s in rvcpp 2023-03-21 21:54:04 +00:00
Luke Wren 410d002372 First pass at adding Zcmp to rvcpp 2023-03-21 21:28:49 +00:00
Luke Wren 8e7e8f4008 Extend rvcpp ISA sim to cover RVC. Passes RV32IC compliance. 2023-03-21 19:38:46 +00:00
Luke Wren 90acfdcbe8 Organise test directory into formal and sim 2021-05-23 07:42:35 +01:00