Skip to content
/ 0dMIPS Public

[WIP] in-order 5(+2)-stages pipeline MIPS64r6el SoC implementation with peripheral components, simulated with verilator

License

Notifications You must be signed in to change notification settings

Nambers/0dMIPS

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

0dMIPS

Codecov

In order 5-stages pipeline MIPS64r6 SoC implementation with peripheral components, simulated and tested with Verilator.

Dependenices

How to run

  1. cmake -B build .
  2. cmake --build build -j ${$(nproc)-1} to build all. All binaries are placed under build/bin
  3. cmake --build build --target help to list all targets
  4. ./runAllTest.sh to run all generated tests under build/bin(by cmake), and use DUMP_COV=1 ./runAllTest.sh to dump coverage data
  5. cmake --build build --target <script_name> to compile script into memory.dat, e.g. fibonacci

Plan

  • Basic 5-stages pipeline
  • TUI GDB-style debugger (simulated)
  • Peripherals by MMIO
    • UART
    • VGA
    • Timer
    • mock stdout
  • Cache
    • L1 inst & data cache and arbiter
  • Interrupts
    • Timer interrupt
    • Break
    • Syscall
  • out-of-order execution double-issue in-order
  • AXI
    • Memory
  • Branch prediction
  • Multiplier/Divider
  • FPU(cp1)

Demo

Hello world with debugger (asciinema)

Hello world with debugger

Simulation file structure

  • debugger_tui GDB-style TUI debugger with information about pipeline(disassembly by capstone), registers, memory, peripherals.
  • SOC_debug enable debug print and press any key to step.
  • SOC_sim run simulation under info log.
  • SOC_run_sim run simulation without info log.
  • SOC_VGA_sim run simulation with VGA output(provided by SDL3).
  • VGA_sim run demo VGA simulation.

Schematic diagram

WIP

Schematic diagram

About

[WIP] in-order 5(+2)-stages pipeline MIPS64r6el SoC implementation with peripheral components, simulated with verilator

Topics

Resources

License

Stars

Watchers

Forks