ptomsich / difftest

Co-simulation framework for Xiangshan

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Difftest Submodule

Difftest (差分测试) co-sim framework

Usage

  1. Init this submodule in your design, add it to dependency list.
  2. Add difftest to your design.
  3. Generate verilog files for simulation.
  4. Assign SIM_TOP, DESIGN_DIR for difftest/Makefile
  5. cd difftest and make emu, then start simulating & debugging!

To use difftest in XiangShan project:

cd XiangShan
make init
# cd difftest
make emu

API

Difftest functions:

  • DifftestArchEvent (essential)
  • DifftestInstrCommit (essential)
  • DifftestTrapEvent (essential)
  • DifftestCSRState (essential)
  • DifftestArchIntRegState (essential)
  • DifftestArchFpRegState
  • DifftestSbufferEvent
  • DifftestStoreEvent
  • DifftestLoadEvent
  • DifftestAtomicEvent
  • DifftestPtwEvent

Simulation top:

  • LogCtrlIO
  • PerfInfoIO
  • UARTIO

Simulation memory:

  • RAMHelper (essential)

To use difftest, include all these modules / simtopIO in your design.

Further reference

About

Co-simulation framework for Xiangshan

License:Other


Languages

Language:C++ 71.3%Language:C 13.4%Language:Scala 6.0%Language:Makefile 5.2%Language:Verilog 4.1%