[ English | 中文 ]
├── src
│ └── main
│ └── scala
│ └── markorv
│ ├── backend # Execution units
│ ├── cache # Cache
│ ├── frontend # Frontend
│ └── io # External bus
└── tests
├── asmtst # Assembly tests
└── emulator # Test stimulus generation
This is a temporary program order definition. Write-back order in the cache is not guaranteed, but the consistency of instruction effects on the internal CPU state is ensured (non-out-of-order execution).
Please refer to TODO.md for future update plans.
Check the docs folder for detailed architecture information and update logs.
-
Clone and init the project
git clone https://github.com/marko1616/marko-riscv.git make init
-
Install build tools
- Install mill 0.11.5 It is recommended to run the following commands:
curl -L https://github.com/com-lihaoyi/mill/releases/download/0.11.5/0.11.5 > mill && chmod +x mill export PATH="$(pwd):/$PATH" # Needs to be added each time you run. Alternatively, modify your bashrc.
-
Run Makefile options
make gen-rom # ⚙️ Generate hex ROM image make gen-tests # ⚙️ Generate hex test assembly programs make compile # ⚙️ Compile C++ emulator
- Modify the parameters in
tests/emulator/stimulus.cpp
- Generate and run the simulation:
make gen-rom make gen-tests make emu obj_dir/VMarkoRvCore --rom-path tests/emulator/assets/boot.bin --ram-path tests/asmtst/xxx.bin