jbush001 / NyuziProcessor

GPGPU microprocessor architecture

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Verilator coverage testing

jbush001 opened this issue · comments

Collect coverage information at end of tests.

https://www.veripool.org/projects/verilator/wiki/Manual-verilator

  1. Pass --coverage option to verilator in makefile
  2. Modify c++ test harness to VerilatedCov::write into an output file. There will be one file per test, which should be collected somewhere (this probably needs to be done by test_harness.py)
  3. Run verilator_coverage executable, passing paths of all output files, which it will consolidate.

It takes a very long time to compile the full processor model with this enabled, which may be prohibitive. This may still be useful for unit tests.