More Draft 4 BNF comments

From: James A. Markevitch (jam@magic.com)
Date: Sun Jan 23 2000 - 11:06:28 PST


More comments on Draft 4 BNF.

Section A.2.3

list_of_local_param_assignments is defined in this section, but is not
used anywhere. The local_parameter_declaration in section A.2.1.1
uses list_of_param assignments.

Section A.6.3

Should function_seq_block have an optional attribute_instance? seq_block
has this, but function_seq_block does not.

Section A.8.4

genvar_primary does not contain "( mintypmax_expression )" or anything
analogous to that. I think this is the right thing, since it is closer
to a constant_primary, rather than a normal primary. Is this definitely
correct?

Sections A.7.3 and A.9.3

input_identifier and output_identifier are defined in two places. I believe
that they should be left in section A.7.3 and removed from section a.9.3.

Section A.2.2.3

delay_value includes mintypmax_expression. Should this be
constant_mintypmax_expression? In 1995 it used the constant version.

<p><p>Constant functions for delays

If a delay_value is allowed to include any constant_mintypmax_expression,
including a constant_function_call, then this creates a tough situation for
parsers. For example,

        udpname #f(a,b) (c,d);

When parsing this, the parser doesn't know, until the second open paren
is encountered, whether or not "(a,b)" is the udp_instance or a list of
arguments to function "f". Since section 10.3.5 does not appear to require
that constant functions be declared before they are used, the parser cannot
even get a hint that "f" is a function. Thus, it must scan until it sees
the second open paren, then make the decision about how to interpret "(a,b)".

Note that such hard-to-parse constructs are not new to Verilog. In 1995,
in the following:
        mod_or_udp #(2) inst_name(a, b, c);
"#(2)" can be either a delay value or a parameter override and cannot be
resolved until elaboration time when it is known whether "mod_or_udp" is a
module or a UDP.

Comments?

<p><p>General comment

Need to add "constant functions" to the index.

James Markevitch



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