Subject: [sv-bc] Questions and potential issue about parameters
From: Francoise Martinolle (fm@cadence.com)
Date: Wed Dec 31 2003 - 09:46:28 PST
The chapter describing parameters in draft 2 is silent about the rules
governing the type of the parameter.
Do the 1364 2001 rules described in sections 3.11.1 and 12.2 also apply to
SV parameters?
I mean for example that it I declare a parameter of type struct, the type
of the parameter will
be that struct type.
In the case where we have a parameter declared as a packed/unpacked struct
or an array, can an expression overridding the parameter value change the
type/range of the parameter?
In the case where we have a parameter declared as a packed/unpacked struct
or an array,
is the initialization expression or any override expression required to be
assignment compatible with the parameter declared type?
I think that we need some kind of clarification, or at least say it follows
the ieee 2001 rules for all datatypes, except when the parameter is a type
parameter, which is a special case.
I think that we should extend the 1364 rules to apply to packed/unpacked
struct and arrays.
Note that if we do this, we have conflicting rules with Verilog AMS which
allows overriding of array parameters to change the size of the array...
Verilog ams allows:
parameter real p [0:2] = {0.1, 0.2, 0.3};
and further on overrides it with a smaller or bigger.
Ex:
#{0.1, 0.2)
This archive was generated by hypermail 2b28 : Wed Dec 31 2003 - 09:49:07 PST