Documentation Center

  • Trial Software
  • Product Updates

Cumulative Coverage Data

On the Results tab, if you select Enable cumulative data collection and Save cumulative results in workspace variable, a coverage running total is updated with new results at the end of each simulation. However, if you change model or block settings between simulations that are incompatible with settings from previous simulations and affect the type or number of coverage points, the cumulative coverage data resets.

You can make cumulative coverage results persist between MATLAB® sessions. The cvload parameter RESTORETOTAL must be 1 in order to restore cumulative results. At the end of the sessions, use cvsave to save results to a file. At the beginning of the session, cvload to load the results.

When you save the coverage results to a file using cvsave and a model name argument, the file also contains the cumulative running total. When you load that file into the coverage tool using cvload, you can select whether you want to restore the running total from the file.

When you restore a running total from saved data, the saved results are reflected in the next cumulative report. If a running total already exists when you restore a saved value, the existing value is overwritten.

Whenever you report on more than one single simulation, the coverage displayed for truth tables and lookup-table maps is based on the total coverage of all the reported runs. For cumulative reports, this information includes all the simulations where cumulative results are stored.

You can also calculate cumulative coverage results at the command line, through the + operator:

covdata1 = cvsim(test1);
covdata2 = cvsim(test2);
cvhtml('cumulative_report', covdata1 + covdata2);
Was this topic helpful?