Subject: Re: Note on NaN
From: Steve Grout (grouts@flash.net)
Date: Thu Nov 01 2001 - 16:39:55 PST
Kevin - Good point and the central point I've been trying
surface throughout this X and Z discussion. Our CENTRAL
focus should be on trying to make sure both X and Z reflect
the modeled HARDWARE (as in "H"DL? :-), and not the foibles
of the underlying implementation software (compiler, loader,
and simulator). Certainly sometimes teh software has to
return some out-of-range value (not VDD-high, not VSS-low,
not high-impedance-so-floating-in-one-direction-or-other)
due to software processing just occurred. An X even there
has to be HDL modelled/processed appropriately so that the
emulated design is kept as accurate as possible, or so the
designer can be informed there is a software emulation problem
somewhere with the HDL and in both cases, the right further
processing and debug happen.
I feel we who practice this craft (simulating design via an
HDL) sometimes begin to make decisions based on the software
we are implementing and not the target hardware we are trying
to describe and 'run' (simulate).
Thanks for helping keep us focused in the right frame of mind.
Regards,
--Steve Grout
>
> >
> > It might be best to propagate both
> > state and value. NaN's should be avoided, since it generally
> > contaminates all associated math. In the past, we usually
> > trapped the NaN interrupt and had a service routine
> > return a large signed number as a limiter. I think of NaN as
> > an overflow, not an unknown.
> >
> > --Kim
>
> That makes sense in an all-analog simulation where NaN would
> probably result from division by zero, however AMS 'X' values
> are not necessarily out-of-range i.e. it is actually a 1,0 or
> 'Z', and will be somewhere between Vdd and Vss.
>
> Users should take responsibility for handling 'X' states in
> their code, having Verilog-AMS discard the fact that a value
> is unknown would lead to code making false assumptions and
> result in non-working Silicon.
>
> Kev.
>
-- --Steve Grout Design Verification, CAD Methodology/R&D, Manager, Individual Contributor - Design Verification, CAD System, Database, Flows, Tools, Integration, and Support for both Digital and Analog/Mixed-Signal Design Teams. 101 Kenneil Court Apex, NC 27502 Phone: 919-303-5066 email: grouts@flash.net http://www.flash.net/~sgrout/Personal/resume2001.pdf (or doc,rtf,txt)
This archive was generated by hypermail 2b28 : Thu Nov 01 2001 - 16:42:11 PST