Code coverage is used to know that how much code simulation able to cover. It is generated from simulation tool with extra arguments given. Here some of commands listed to generated code coverage by using different simulators.
Add following with compile command
- VCS : -cm line+cond+fsm+tgl+branch+assert -cm_dir $(PHY_SIM_LOG).vdb
- Questa : +cover=bcesxf -coveropt 1
- IRUN :
Simulation command :
- Questa : coverage save -onexit $(PHY_SIM_LOG).ucdb ( add in simulation do file)
To merge coverage from all tests following commands can be used .
- VCS. : bsub -I urg -report merge_rpt -dbname merge.vdb -f list_vdb
- Questa.: vcover merge -out merge.ucdb -inputs list_ucdb