Re: Compiler directives ( timescale)

From: Adam Krolnik (adamk@cyrix.com)
Date: Wed Apr 15 1998 - 02:37:42 PDT


Good afternoon:

<p>Stuart writes:
>Personally, I do not see a need for changing the nature of `timescale. Its
>behavior of affecting all modules which follow the directive is consistent
>with all other compiler directives, and has the same practical uses as well
>as inherent hazards. It simply requires that modelers have the common
>sense and self discipline to place a `timescale directive before their own
>modules. That is just good coding style. In many (all?) aspects of

One could argue that many hazards could be avoided if good coding styles were
utilized. But restrictions have been added to the language to avoid hazards
as well as warnings. Many times, coding styles evolve because situations
change. What was not a problem before becomes a problem with changes. If
people see things as pitfalls, there are language devices to keep
people away from problematic coding. This is what I'm hoping to discover -
do others see this as a problem that would benefit from an alternate way.

Here I tend to see the nature of `timescale as a compiler directive in combination
with libraries (files, directories) and foreign source code creates a mix where
adding one instantiation or new module can alter the operation of correct code.
Yes, if you are very conservative, you can specify all optional language aspects
when you write code to guard against all pitfalls. You can take this as far
as requiring `timescale, `resetall at the end of a file, parenthesis
everywhere, include all needed files, etc.

>The one thing lacking in the current `timescale behavior is that there is
>no standard default time unit and precision. This was discussed for the
>1995 standard, and decided to purposely omit from the standard because
>every existing simulator had implemented different defaults (or no default
>in the case of Verilog-XL)

Lack of expected or default behavior is something a standard should seek to
define. Can we flip a coin to pick something if noone wants to define it
because they might have to do some work and the other vendor would not?

<p> Adam Krolnik



This archive was generated by hypermail 2.1.4 : Mon Jul 08 2002 - 12:52:48 PDT and
sponsored by Boyd Technology, Inc.