From a7f8c9cc74a177d276eca458504f38cb40b187e8 Mon Sep 17 00:00:00 2001 From: Wilson Snyder Date: Thu, 5 Dec 2024 08:54:00 -0500 Subject: [PATCH] Commentary --- docs/guide/simulating.rst | 24 ++++++++++++++++-------- 1 file changed, 16 insertions(+), 8 deletions(-) diff --git a/docs/guide/simulating.rst b/docs/guide/simulating.rst index f62bada5c..6a3484c7f 100644 --- a/docs/guide/simulating.rst +++ b/docs/guide/simulating.rst @@ -224,14 +224,6 @@ at branches). At each such branch, a counter is incremented. At the end of a test, the counters, filename, and line number corresponding to each counter are written into the coverage file. -Verilator automatically disables coverage of branches with a $stop in -them, as it is assumed that $stop branches contain an error check that should -not occur. A :option:`/*verilator&32;coverage_block_off*/` metacomment -will perform a similar function on any code in that block or below, or -:option:`/*verilator&32;coverage_off*/` and -:option:`/*verilator&32;coverage_on*/` will disable and enable coverage -respectively around a block of code. - Verilator may over-count combinatorial (non-clocked) blocks when those blocks receive signals which have had the :option:`UNOPTFLAT` warning disabled; for the most accurate results, do not disable this warning when @@ -278,6 +270,22 @@ A :option:`/*verilator&32;coverage_off*/` signals that do not need toggle analysis, such as RAMs and register files. +.. _Suppressing Coverage: + +Suppressing Coverage +-------------------- + +Using :option:`/*verilator&32;coverage_off*/` and +:option:`/*verilator&32;coverage_on*/` around a block of code will disable +and enable coverage respectively around that block. Or, use the +:option:`coverage_block_off` configuration file option. + +Verilator automatically disables coverage of lines and branches with a +$stop in them, as it is assumed that $stop branches contain an error check +that should not occur. A :option:`/*verilator&32;coverage_block_off*/` +metacomment will perform a similar function on any code in that block or +below. + .. _Coverage Collection: Coverage Collection