RE: [sv-bc] Query on bind

From: Saikat Bandyopadhyay <saikat_at_.....>
Date: Mon Feb 25 2008 - 21:28:20 PST
Hello Gord,

Thanks a lot for your reply.
Yes, the section mentioned by you is good enough to avoid
any circular dependency. However bind support without scope
can result in some severe inefficiency in elaboration.
Please consider the following example

module top(...)
  mid m1(...);
  mid m2(...);
  ...
  mid mN(...);
  mid2 mm(...);
endmodule

module mid(...);
...
endmodule

module mid2(...);
  mid m1(...)
  mid m2(...)
  generate
  if (p=1) begin
    mid m3(...);
    mid m4(...);
    bind mid mid_verif mv(...);
  end
  endgenerate
endmodule

module mid_verif(...);
...
endmodule

Please note that bind construct in mid2 is under generate and we
are not sure if this will occur in the true path until the elaboration
of mid2. By that time elaboration of lot of instances of mid has
happened(may be with different parameters). To support this we
will have to "restart again from top and add binded instance in
all pre-elaborated copies of mid" and ofcourse in the unelabotated
mid, for correct down the line elaboration of yet unelaborated
instances of mid.

Any clarification, comments on this will be appreciated.

Thanks,
Saikat

> -----Original Message-----
> From: Gordon Vreugdenhil [mailto:gordonv@model.com]
> Sent: Monday, February 25, 2008 8:53 PM
> To: Saikat Bandyopadhyay
> Cc: sv-bc@eda.org
> Subject: Re: [sv-bc] Query on bind
> 
> 
> The bind descriptions in 17.15 (1800-2005) and 22.10 (2008 Draft 4)
> both have:
> 
>     Any defparam statement located at a lower level of the
>     bind_instantiation's hierarchy must not extend
>     influence outside the scope of that local hierarchy.
>     This is similar to the rules for use of defparam inside the
>     scope of generated hierarchy.
> 
> Is that not sufficient?
> 
> Gord.
> 
> Saikat Bandyopadhyay wrote:
> > Hello,
> >
> >
> >
> > P1800 LRM 2005 says the following on Bind construct
> >
> >
> >
> > *17.15* *Binding properties to scopes or instance*
> >
> >
> >
> > ..
> >
> > ...
> >
> > There are two forms of bind syntax. In the first form, bind_target_scope
> > specifies a target scope into which
> >
> > the bind_instantiation should be inserted. Possible target scopes
> > include module, program, and interface
> >
> > declarations. In the absence of a bind_target_instance_list, the
> > bind_instantiation is inserted into all
> >
> > instances of the specified target scope, designwide.
> >
> >
> >
> > Bind without instance list, is applied to all instance in the design,
> > irrespective of where bind is declared.
> >
> > That means if such bind construct appears in design top, middle or
> > bottom, it has the same impact.
> >
> > Is this interpretation correct? If not please let me know the correct
> > interpretation.
> >
> >
> >
> > If the impact for instance-less bind is designwide, then it is somewhat
> > similar to defparam. Defparam inside
> >
> > generate block cannot change parameter outside the block as per 1364 LRM
> > 2005
> >
> >
> >
> > *12.2.1 defparam statement*
> >
> >
> >
> > Using the defparam statement, parameter values can be changed in any
> > module instance throughout the
> >
> > design using the hierarchical name of the parameter. See 12.5 for
> > hierarchical names.
> >
> > However, a defparam statement in a hierarchy in or under a generate
> > block instance (see 12.4) or an array of
> >
> > instances (see 7.1 and 12.1.2) shall not change a parameter value
> > outside that hierarchy.
> >
> >
> >
> > I believe similar limitation on bind is needed for a clean elaboration
> > flow. Please give your comments on this.
> >
> >
> >
> > Thanks,
> >
> > Saikat
> >
> >
> > --
> > This message has been scanned for viruses and
> > dangerous content by *MailScanner* <http://www.mailscanner.info/>, and
> is
> > believed to be clean.
> 
> --
> --------------------------------------------------------------------
> Gordon Vreugdenhil                                503-685-0808
> Model Technology (Mentor Graphics)                gordonv@model.com
> 





-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
Received on Mon Feb 25 21:29:19 2008

This archive was generated by hypermail 2.1.8 : Mon Feb 25 2008 - 21:29:56 PST