Академический Документы
Профессиональный Документы
Культура Документы
User Guide
Version X-2005.12
December 2005
Comments?
E-mail your comments about this manual to
vera_support@synopsys.com
Copyright Notice and Proprietary Information
Copyright 2005 Synopsys, Inc. All rights reserved. This software and documentation are owned by Synopsys, Inc.,
and furnished under a license agreement. The software and documentation may be used or copied only in accordance
with the terms of the license agreement. No part of the software and documentation may be reproduced, transmitted,
or translated, in any form or by any means, electronic, mechanical, manual, optical, or otherwise, without prior written
permission of Synopsys, Inc., or as expressly provided by the license agreement.
Right to Copy Documentation
The license agreement with Synopsys permits licensee to make copies of the documentation for its internal
use only. Each copy shall include all copyrights, trademarks, service marks, and proprietary rights notices,
if any. Licensee must assign sequential numbers to all copies. These copies shall contain the following leg-
end on the cover page:
This document is duplicated with the permission of Synopsys, Inc. for the exclusive
use of __________________________________________ and its employees. This
is copy number __________.
1
FSM . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-22
Assertions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-24
Testbench. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-25
Coverage Analysis. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-26
Grading . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-26
Grading and the -scorefile Option . . . . . . . . . . . . . . . . . . . . . . 1-27
Command Line . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-28
Directories . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-28
Coverage Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-29
Controlling the Report Format . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-29
Grading and Analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-30
Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-31
Known Issues . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-32
2
1
Unified Coverage Reporting 1
The Unified Report Generator (URG) generates combined reports for
all types of coverage information. The reports may be viewed through
the design hierarchy, module lists, coverage groups, or through an
overall summary "dashboard" for the entire design/testbench. The
reports consist of a set of HTML or text files.
The HTML version of the reports take the form of multiple interlinked
HTML files. For example, a "hierarchy.html" page shows the design's
hierarchy and contains links to individual pages for each module and
its instances.
The HTML file that the URG writes can be read by any web browser
that supports CSS (Cascading Style Sheets) level 1, which includes
Internet Explorer (IE) 5.0 and later versions, any version of Opera,
and the later versions of Netscape.
To invoke URG, enter the urg command and specify the directories
containing coverage data files.
Data files are grouped into tests based on the names of the files. So
if you have:
./simv.vdb/snps/coverage/db/testdata/test1
./simv.cm/coverage/verilog/test1.db
./simv.cm/coverage/vhdl/test1.db
./simv.vdb/fcov/test1.db
All of these files will be considered data for 'test1'.
Code coverage
- line
- condition
- toggle
- FSM
Assertions
Testbench
Note: You can only report on code or assertion coverage if you use
VCS code or assertion coverage to collect data.
dashboard
hierarchy
modlist
groups
modN.html or modinfo.txt
grpN.html or grpinfo.txt
-line nocasedef Exclude case default from line line coverage only
coverage reports
-show tests Show the tests that covered each line line & condition
and condition coverage
-show maxtests N Specify the maximum number of tests
with "-show tests"
-grade goal timelimit Grade tests (see page 26)
-scorefile filename Allows user to specify different weight
to each metric
Generated Files
Coverage data boxes are used throughout the URG report pages.
These are tables containing one box for each type of coverage.
The first box shown is the overall score for all metrics. By default, this
is the simple average of all the metric percentages. You can control
the way the score is computed with the -scorefile option (see
Grading and the -scorefile Option on page 1-27).
The Line box is green because it falls into the upper range of target
values. Values display in a range of 11 colors from red (low) to green
(high) as shown below. These colors are graduated every 10
percentage points (with 100 being the 11th class).
Note that you can weight the coverage score in various ways. For
example, 60% assertions coverage may be much worse than 25%
condition coverage.
Note: The following examples are shown in HTML. The text versions
of these pages contain the same content, but are missing the
hyperlinks and color.
"modlist" File
"groups" File
"tests" File
This page lists, in score order, all tests whose coverage data was
loaded to generate the report. Tests are listed in overall coverage
score in best-first order, unless the report was produced with grading,
in which case they are listed in graded order (see Grading and
Analysis on page 1-30). There will always be at least one test in the
tests.html page.
"modN" File
Coverage data boxes are shown for the module summary information
and for each of its instances so users can see the status of each. The
The module instance sections also have header and coverage data
sections. The header is similar to the module header, but instead of
source file and self instance lists, links to the parent instance and to
child instances are shown.
Smaller coverage data boxes are shown for the module summary
information, the parent, and each child of the module instance. The
As for all report pages, the coverage data boxes are linked to the
corresponding coverage reports. For example, clicking on "Line" in
the above example would display the line coverage information for
the module instance "DUT.KPU0.MA.arbfGRLNK2". These links are
convenient for movement within a modN.html page, and are also the
only way to view the coverage data reports if the modN.html page
has been split for size.
"grpN" File
The names of the variables and crosses in these tables are linked to
their details.
Three special files are generated for assertion and property coverage,
asserts.html, assertcategories.html and assertseverities.html.
The asserts.html page below shows the score for each category and
severity of assertions, properties and sequences.
Coverage Data
Common Elements
There are two basic types of display that will be used for showing
coverage results. One is the statistics table, and the other is the table
of coverable objects.
As shown in the example, statistics tables are colored using the same
percentages used for coverage data boxes.
For all types of coverage, the data section will begin with a statistics
table showing the basic categories (for example, lines, statements,
and blocks, or logical and non-logical conditions). This will be followed
by a table of coverable objects.
Note that several metrics have options that change exactly what is
covered or how it is output. For example, condition coverage has
-cm_cond allops+anywidth, which affects which vectors and
conditions are monitored for coverage. Unless otherwise specified
below, these options will not affect the basic structure of the coverage
data output.
The line coverage section will begin with a table showing the overall
coverage for lines, statements, and blocks. It will then show a
summary of the coverage data for all types of blocks (always,
caseitem, for, forever, etc.).
The other type of coverage data currently in the line reports is a table
showing the line number of each statement, 0 or 1 for not covered/
covered, and then the block type if that statement begins a block.
Toggle
The toggle coverage report starts with a table containing the number
of Nets, Regs, and VHDL signals, the bits in each, and the summary
coverage statistics for each type of signal. It then shows a table for
each type of signal, listing each signal and indicating whether it was
fully covered or not.
FSM
The FSM coverage section will begin with a summary table for states,
transitions, and sequences for all FSMs in the module/instance/entity.
Each coverage group section lists all points and crosses and their
coverage scores at the top.
There will then be a section for each point or cross, showing the
individual coverage percentage, information about the point or cross,
and other information essentially in the same format as the current
testbench coverage reports.
Coverage Analysis
Grading
When the -grade option is given to URG, it will grade all of the tests
that are provided as input to URG.
When grading is specified, the tests.html page will list the tests in
three sections. The first section will list the tests in graded order,
showing the incremental coverage scores for each test with respect
to the tests above it in the list. The second section consists of a simple
list of tests that were not used to reach the grading goal (or were not
useful). In the third section, all tests will be listed in descending order
of overall coverage score.
Note that if the time limit is specified, only those tests that are graded
before the time limit is hit will be included in the graded list. Only the
data for those tests will be used to generate the report files, even if
the grading goal is not reached.
Then each line and assertion will be considered with the same weight
when grading tests. This will be as if the coverage percentage of a
given test is the number of covered lines plus the number of covered
assertions, divided by the total number of lines plus the total number
of assertions. We will use the same basic grading algorithm (test
loading/unloading of all data from that test) as in the single metric
case, but compute the percentages in this unified way.
line 1
tb 2
The names of the metrics in the score file are the same name used
as arguments to the -metric flag. As for the unified grading example
in the last section, we use the same grading algorithm. The only
difference is how we compute the coverage percentages. In this
example, the total coverage percentage would be computed as the
mean of the scores for line and twice the testbench coverage.
Directories
-dir directory
This option will accept any coverage directory (.cm, .vdb, and any
future unified directory form) and take data from that directory for its
report. Multiple -dir options can be specified. You must specify at
least one directory - there is no default coverage directory name.
-metric [+]line+cond+fsm+tgl+assert+tb
-show tests
-show maxtests N
These options only apply to line and condition coverage. When given,
for line and condition coverage, the reports will show which tests
covered each line or condition.
You can use the -scorefile option to modify how the "worst first"
score is computed. URG uses a default algorithm for computing this
- each metric is weighted the same. If a -scorefile file is specified,
the weights in the score file are used instead.
metric1 weight1
metric2 weight2
metricN weightN
Each metric may only be specified one time in the file. The metric
names are the same as those used for the -metric option on the
Note that grading may be restricted to only certain parts of the design
using the -hier or -map options. When these options are used with
grading, the tests are ranked in order based only on their effects on
the specified parts of the design.
Example
% urg -dir .
Known Issues