This is a pure systemverilog/verilog Testbench for risc-v SoCs. Those SoCs can be be generated by chipyard.
In chipyard simulation, the DUTs(risc-v cores) is tethered, which means the DUT(cores) can not be boot from memory automaticly.
And in this testbench , we build a testbench for standalone DUT which means the core can bringup itself (has its own bootrom, loads programs itself, etc).
Make sure you have RISC-V gcc toolchain installed.
Make sure the EDA simulation tools(VCS) is installed.
cd ./bootrom;
make hex;
you can see a .hex file is generated in this folder.
cd ./case;
make all;
you can see a .hex file is generated in this folder.
cd ./vsim;
make run;
you can see the the string "Hello RISC-V!" is printed on the terminal. And a .fsdb waveform is emmited in the folder.
Tips: for more commands just refer to the Makefiles.
bootrom assemble program which will be loaded in the maskrom(Address:0x10000)
CPU initial programs and user programs.
Most of the code is porting from sifive freedom platform.
RISC-V SoC RTL files. Those files is generated by chipyard from chisel.
SystemVerilog testbench files.
Scripts for VCS Simulation.
The following repo is referenced.