unresolved old issues

From: Geoffrey.Coram <Geoffrey.Coram@analog.com>
Date: Fri May 28 2004 - 12:37:29 PDT

I was perusing the VAMS reflector archive, and I came
across two issues that were brought up but not resolved
in the e-mails.

1) localparams and overrides by order: Sri asked how one
could override the value of L in this example:

module blackbox();
parameter real R = 10.0;
localparam K = 3;
parameter real L = 0.1;

One suggestion was that localparams would be ignored
when making the associations. I can't see that this
was addressed in Verilog-2001 or in the 2005-d2.
I proposed that aliasparams follow this rule.

2) Ranges for built-in functions: Sri asked about
the ranges for the built-in math functions:

For sinh(x), it should probably be |x| < 80 instead of x < 80,
For cosh(x), it shoud probably be |x| < 80, instead of x < 80.

for atanh(x), -1 < x < 1, instead of -1 <= x <= 1

but these did not make it into LRM 2.1

I'm actually curious where the "80" came from. exp(x) is
also restricted to x<80. Does that make any sense, really?
It looks like it was derived from ln(MAXFLOAT). But if
I ask for pow(10,80), the LRM doesn't have a constraint.

I think that the restrictions should be removed from exp(),
sinh(), and cosh(). If there was some reason for the
restrictions, then a more general statement should be
inserted, saying what should happen when a floating-point
exception is raised for any math operation, whether from
these operators directly or some other expression.

-Geoffrey
Received on Fri May 28 14:29:19 2004

This archive was generated by hypermail 2.1.8 : Fri May 28 2004 - 14:29:43 PDT