Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hi,
this is a proposal for fixing the generate scopes not being emitted as coverage "instance" scopes.
It works well for
for generate
becauseT_BLOCK
name for the generate has iterator variable suffix.In case of
if generate
orcase generate
, only a single block is elaborated at single simulation.A branch / choice inherits name of the parent generate statement, unless overridden by a branch / choice
specific
alternative_label
. If user omitsalternative_label
, than different HDL items may end up withthe same code coverage item name (in a different elaborations / simulations). When merging the code
coverage data from such simulations, such data aliases.
Consider e.g. following example:
Where
G_PAR
is a top level generic of the entity instantiating thiscase generate
statement.Upon elaborations with
G_PAR
ranging from 0 to 3, each of the signal assign statements fromc
up tof
will have following coverage item name:since the implicit statement / process / branch / expression labelling always counts the equally
within distinct coverage scopes. Merging of code coverage from such simulations gives confusing
results and false positives.
An obvious approach how to fix this, would be appending the branch / choice index to a name
of implicit block that is created for such choice / branch. Such "conflict avoidance" would work
very similarly to implicit labelling of statements / processes / expressions for code coverage.
Do you think it is better to append such "implicit counter" to the name of the created code coverage
scope only, or to the name of the implicit block ? Or would you choose another approach ?