https://github.com/technius/toyrisc
A toy RISC-V simulator
https://github.com/technius/toyrisc
Last synced: 11 months ago
JSON representation
A toy RISC-V simulator
- Host: GitHub
- URL: https://github.com/technius/toyrisc
- Owner: Technius
- License: apache-2.0
- Created: 2021-02-10T07:27:40.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2021-02-10T07:28:11.000Z (over 5 years ago)
- Last Synced: 2025-01-31T12:24:43.893Z (over 1 year ago)
- Language: Rust
- Size: 16.6 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ToyRISC
This is a toy RISC-V simulator.
# Notes
* Only way to change privilege mode is through `ECALL` and `MRET`/`SRET`.
* `MRET`/`SRET` will change the privilege mode to the one in `MSTATUS.MPP`
* Traps switch machine to M-mode unless `mdeleg` is set.
* "privilege mode stack"?
* https://cdn2.hubspot.net/hubfs/3020607/An%20Introduction%20to%20the%20RISC-V%20Architecture.pdf