These are some more follow-up questions on mantis #2993:
1. "pe" and "op" are instantiated within covergroup "stage_corners". How these two instances
impact coverage of an instance of "stage_corners"? My understanding is that the user intent
in this case is to just declare a cross in covergroup "stage_corners". In that case, none of
the coverpoints in "op" and "pe" will be considered as part of "stage_corners". Is this correct
understanding or there is something which I am missing?
2. If user has created only one instance of "stage_corners", only that instance will be reported
to the user. None of the instances "pe" and "op" which are created internally by "stage_corners"
will be reported. Is that correct?
3. If user has created one normal instance "pe_1" of "pipe_events" outside "stage_corners" and
one instance "stgc_1" of "stage_corners", only "pe_1" and "stgc_1" will be reported to user.
"pe" and "op" will not be reported. Also "pe" will not contribute to type-based coverage of
"pipe_events". Is this correct?
4. Have we brainstormed introducing an explicit constructor (new) for covergroup as well? In that
case, we could represent the mantis example as below. This looks very much like class constructors
and more intutive. Given the fact we have added override for sample, this may be an option to
override "new".
covergroup stage_corners(ref bit ovr_bit, ref bit udr_bit, ref bit err ..., ref bit [71:0] op, ref bit[1:0] precision);
pipe_events pe;
opcodes op;
function new(...);
pe = new(ovr_bit, udr_bit, err,...;
op = new(op, precision);
endfunction
cross pe op.op.prec;
endgroup
Regds,
Swapnajit
________________________________
From: Swapnajit Chakraborti
Sent: Tuesday, June 08, 2010 1:00 PM
To: sv-ec@eda.org
Cc: Swapnajit Chakraborti
Subject: Query on mantis 2993 (in top 25 list)
Hi All,
As per following mantis (included in top 25 list):
0002993: Cross cover points across different cover groups
instantiation of covergroups is allowed within covergroups (shown below):
covergroup stage_corners(ref bit ovr_bit, ref bit udr_bit, ref bit err ..., ref bit [71:0] op, ref bit[1:0] precision);
pipe_events pe = new(ovr_bit, udr_bit, err,...; <<---- new inside covergroup
opcodes op = new(op, precision); <<--- new inside covergroup
cross pe op.op.prec;
endgroup
Is this syntax finalized? These are variable decl assignment statements. Are we planning to allow
such statements within covergroup just to support hierarchical crosses?
There could be an alternate approach if we allow covergroup modeling just like classes and allow
multiple inheritance for covergroups as well. In that case the covergroup which needs to use
hierarchical cross can extend itself from all those covergroups whose coverpoints it wants to
reuse and then just writes the cross. This will probably be more intuitive and more aligned towards
making covergroups like classes.
Regds,
Swapnajit
-- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean.Received on Tue Jun 8 04:33:33 2010
This archive was generated by hypermail 2.1.8 : Tue Jun 08 2010 - 04:33:54 PDT