Re: [sv-ec] Query on get_coverage()

From: Saurabh Sharma <saurabhs_at_.....>
Date: Mon Sep 01 2008 - 21:55:42 PDT
Hi Swapnajit,

As stated in the text quoted get_coverage() is a static method.

In the case when it is called on covergroup instance i.e
cgi.get_coverage();

Applying the OOPS concepts it should return the cumulative coverage of the
Type of covergroup Instance on which it is invoked.

Thanks
Saurabh

Swapnajit Chakraborti wrote:

> Please note the following excerpt from P1800-2009, draft6:
>  
> "The get_coverage() method returns the cumulative (or type) coverage, 
> which considers the contribution
> of all instances of a particular coverage item; and it is a static 
> method that is available on both types (via the
> :: operator) and instances (using the . operator). In contrast, the 
> get_inst_coverage() method returns
> the coverage of the specific instance on which it is invoked; thus, it 
> can only be invoked via the *. *operator."
>  
> The above para mentions that get_coverage() can be used with 
> covergroup instance also. So, in the following
> example, would both get_coverage() and get_inst_coverage() report same 
> numbers? If they are same, what
> is the justification of allowing get_coverage() for instances?
>  
> cg cgi = new;
> cgi.get_coverage();
> cgi.get_inst_coverage();
>  
> Thx,
> Swapnajit
>
> -- 
> This message has been scanned for viruses and
> dangerous content by *MailScanner* <http://www.mailscanner.info/>, and is
> believed to be clean. 



-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
Received on Mon Sep 1 21:56:17 2008

This archive was generated by hypermail 2.1.8 : Mon Sep 01 2008 - 21:56:58 PDT