Re: [sv-ec] Completing my coverage thought...

From: Swapnajit Chakraborti <swapnaj_at_.....>
Date: Mon Jan 16 2006 - 23:40:30 PST
Hi Arturo & Gord,

As per LRM, coverage for a coverpoint (section 18.10.1)
is defined as:
  num_covered_bins/num_all_defined_bins

Again, num_covered_bins is actually the number of bins for which
at_least count is reached (count >= at_least). 

Now, in your discussion you have mentioned "num_non_empty_bins".
I am assuming the following definition of "num_non_empty_bins".

num_non_empty_bins = num_covered_bins ( count >= at_least) + 
                     (number of bins which have 0 < count < at_least) 

Is the above definition correct?

In that case, if we define coverage as follows (as you mentioned):
> >       num_covered_bins / num_non_empty_bins

We are completely removing the number of empty bins from
the denominator. 

Shouldn't the denominator be the total number of bins defined for 
a coverpoint which is:
num_all_defined_bins = num_non_empty_bins + num_empty_bins

Note that num_all_defined_bins will not include ignore/illegal bins.

Thx,
Swapnajit.

Gordon Vreugdenhil wrote:
> 
> Arturo Salz wrote:
> > Gord,
> >
> > I agree that it's best to not consider empty bins and compute coverage
> > as:
> >       num_covered_bins / num_non_empty_bins
> > While both mechanisms described by you allow coverage to be 100%, this
> > one also exhibits the nice property of being 0 when nothing is run. I
> > believe
> > it is counterintuitive to have non-zero coverage when no bins are
> > covered.
> >
> >       Arturo
> 
> Arturo,
> 
> That's fine with me.  An edge case -- 18.10.1 doesn't define any rules for
> results when the number of non-empty bins is 0.  So, should this be
> defined to be:
>    1) illegal
>    2) 100% coverage
>    3) 0% coverage
> 
> I don't think I would want (1) to be an LRM requirement (an implementation
> might warn of course), but for parameterized ignore_bins, etc. the situation
> might actually be reasonable.
> 
> If the user anticipates the scenario, I think that (2) is the best
> choice since otherwise full coverage can't be reached.
> 
> Gord.
> 
> >
> >
> > -----Original Message-----
> > From: owner-sv-ec@eda.org [mailto:owner-sv-ec@eda.org] On Behalf Of
> > Gordon Vreugdenhil
> > Sent: Monday, January 09, 2006 12:52 PM
> > To: SV_EC List
> > Subject: [sv-ec] Completing my coverage thought...
> >
> > Just to complete my thought regarding coverage before the
> > call was dropped -- my basic question is whether the coverage
> > percentage is:
> >      num_covered_bins / num_non_empty_bins
> > or:
> >      (num_covered_bins + num_empty_bins) / (num_non_empty_bins +
> > num_empty_bins)
> >
> > (i.e. is an empty bin not considered at all or is it
> > trivially covered?)
> >
> > I think that the former is perferable, but I don't know for sure.
> >
> > Gord.
> 
> --
> --------------------------------------------------------------------
> Gordon Vreugdenhil                                503-685-0808
> Model Technology (Mentor Graphics)                gordonv@model.com
Received on Mon Jan 16 23:40:46 2006

This archive was generated by hypermail 2.1.8 : Mon Jan 16 2006 - 23:41:38 PST