RE: [sv-ec] Defining range of bins in coverpoint

From: Yoo, Byung C <byung.c.yoo_at_.....>
Date: Tue Dec 23 2008 - 18:18:25 PST
Hi Saurabh,

Thank you for the clarification.

Some simulator translated the LRM in such a way that const construct can not be used in range.
If const construct can be used, it will be much more flexible and I can avoid passing many covergroup arguments to some extend.

It looks like that variable can be used if there is a way to make sure that the variables will not change once the covergroup is constructed.
Would it be the programmer's responsibility?
Just a thought...

Thanks,

Byung

-----Original Message-----
From: Saurabh Sharma [mailto:saurabhs@cadence.com] 
Sent: Monday, December 22, 2008 8:21 PM
To: Neil.Korpusik@Sun.com; SV_EC List
Cc: Yoo, Byung C
Subject: Re: [sv-ec] Defining range of bins in coverpoint


Hi Byung,

     Using variables with in bin ranges may cause many conflicts. Taking 
an example of a fixed sized bin
           bins fixed [4] = {[1 : ddr_max]};

    If at simulation time we are changing the value of  "ddr_max" than  
the actual distribution of values
    according to size will get changed at the simulation time. This is 
certainly not intended.

   Regarding  using covergroup arguments there are two rules which makes 
them constant as compared a simple variable.
   In section 18.3 :: Input arguments will not track the value of their 
arguments; they will use the value passed to the new operator.
   In section 18.5 :: The open_range_list used to specify the set of 
values associated with a bin shall be constant expressions
                              , instance constants (for classes only), 
or non-ref arguments to the coverage group.

As constant expressions and instance constants (for classes ) are 
allowed in bin ranges so  run-time constants using const
construct should also be allowed.


Thanks
Saurabh Sharma
saurabhs@cadence.com


Neil Korpusik wrote:

> <forwarding email from new member>
>
> Questions such as this should go to the following email address.
>
>     sv-ec@eda.org
>
>
>
>
> -------- Original Message --------
> Subject:     Defining range of bins in coverpoint
> Date:     Thu, 18 Dec 2008 09:28:22 -0700
> From:     Yoo, Byung C <byung.c.yoo@intel.com>
>
>
> Hi
>
> I just subscribed to the mail list as I was instructed by Maidment,
> Matthew R, Levy, Yossef (DT) at Intel Corporation.
>
> I am not sure if I am sending email to the right address. Please let me
> know what I should do if this it not he right process.
>
> There is a question/suggestion for enhancement as described below.
>
> When I define the range of a bin in coverpoint, I found that it is
> strange that variables can be used as range of bins only if they are
> covergroup argument
>
>
> addr: coverpoint  iT.address iff (iT.cmd == MEM_WRITE || iT.cmd == 
> MEM_READ)
>       {
>          bins memory = {[0:ddr_max]};  // Memory space
>        }
>
>
> I could use neither any other variables nor const constant.
> There are many randomly generated variables before the covergroup is
> generated.
> It will be convenient if I can use them directly without having to use
> covergroup argument.
>
> Does this make sense?
>
> Thanks,
> Byung Yoo
>
> DHG
> Intel Corporation
>


-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
Received on Tue Dec 23 18:19:29 2008

This archive was generated by hypermail 2.1.8 : Tue Dec 23 2008 - 18:20:15 PST