From: Michael McNamara (mac@verisity.com)
Date: Mon Dec 04 2000 - 06:00:11 PST
Dhiraj Raj writes:
> Hi Mike
>
> Have you all been able to fix the BNF to correctly handle the
> task/function port declarations. Can you pl. send me a .pdf
> file of the corrected BNF ASAP.
>
> Thanks
> Dhiraj
Dhiraj: Here is the corrected BNF; I'd appreciate your feedback as soon as you
can.
To the Paul, and the BTF: Dhiraj astutely noted that our
implementation of the ansi port enhancement, and task/function
enhancements resulted in a BNF that allowed wire declarations in tasks
and functions. The following correction of that errata should be
rushed into the 1364-2000 standard. Please check to make sure this is
OK.
Once two days have passed by, I will email this to the
1364core@ovi.org; so please correct my errors now!
---------------------------
Add the following productions to A.2.1.2 Port declarations:
---------------------------
tf_input_declaration ::= input [ signed ] [ range ] list_of_port_identifiers
tf_output_declaration ::= output [ reg ] [ signed ] [ range ] list_of_port_identifiers
| output reg [ signed ] [ range ] list_of_variable_port_identifiers
| output [ output_variable_type ] list_of_port_identifiers
| output output_variable_type list_of_variable_port_identifiers
tf_inout_declaration ::= inout [ signed ] [ range ] list_of_port_identifiers
---------------------------
and change function and task to be:
---------------------------
A.2.6 Function declarations
function_declaration ::= function [ automatic ] [ signed ] [ range_or_type ]
function_identifier ;
function_item_declaration { function_item_declaration }
function_statement
endfunction
| function [ automatic ] [ signed ] [ range_or_type ]
function_identifier ( function_port_list ) ;
block_item_declaration { block_item_declaration }
function_statement
endfunction
function_item_declaration ::= block_item_declaration
| input_declaration
function_port_list ::= { attribute_instance } tf_input_declaration
{ , { attribute_instance } tf_input_declaration }
range_or_type ::= range | integer | real | realtime | time
<p>A.2.7 Task declarations
task_declaration ::= task [ automatic ] task_identifier ;
{ task_item_declaration }
statement
endtask
| task [ automatic ] task_identifier ( task_port_list ) ;
{ block_item_declaration }
statement
endtask
task_item_declaration ::= block_item_declaration
| { attribute_instance } tf_input_declaration ;
| { attribute_instance } tf_output_declaration ;
| { attribute_instance } tf_inout_declaration ;
task_port_list ::= task_port_item { , task_port_item }
task_port_item ::= { attribute_instance } tf_input_declaration
| { attribute_instance } tf_output_declaration
| { attribute_instance } tf_inout_declaration
---------------------------
>
> >----- Begin Included Message -----
> >
> > >From stuart@sutherland-hdl.com Mon Nov 13 11:29 PST 2000
> >X-Sender: stuart@mail.sutherland-hdl.com
> >Date: Mon, 13 Nov 2000 09:57:17 -0800
> >To: Dhiraj Raj <draj@cupertino.synopsys.com>
> >From: Stuart Sutherland <stuart@sutherland-hdl.com>
> >Subject: Fwd: RE: Fwd: task/function port declarations
> >Mime-Version: 1.0
> >
> >Diraj,
> >
> >Sorry for the slow response. I've been out of the country on business, and
> >was not able to access my e-mail. I forwarded your message this morning,
> >and received the following response.
> >
> >Stu
> >
> > >From: Michael McNamara <mac@verisity.com>
> > >Date: Mon, 13 Nov 2000 08:22:25 -0800 (PST)
> > >To: Stuart Sutherland <stuart@sutherland-hdl.com>
> > >Cc: btf@boyd.com
> > >Subject: RE: Fwd: task/function port declarations
> > >X-Mailer: VM 6.72 under 21.1 (patch 12) "Channel Islands" XEmacs Lucid
> > >Reply-To: mac@verisity.com
> > >
> > >
> > >Stu, you are correct, that the BNF is in error.
> > >
> > >Essentially, two proposals met and crashed. One had us doing better
> > >ports for modules; another had us adding port lists to tasks and
> > >functions.
> > >
> > >I will create correct BNF and send it to the BTF by the end of today.
> > >
> > >
> > >Stuart Sutherland writes:
> > > > BTF,
> > > >
> > > > I received the following concern regarding the BNF and the new combined
> > > > port/type declarations.
> > > >
> > > > Stu
> > > >
> > > > >From: Dhiraj Raj <draj@cupertino.synopsys.com>
> > > > >Date: Wed, 8 Nov 2000 11:59:56 -0800 (PST)
> > > > >To: stuart@sutherland-hdl.com
> > > > >Subject: task/function port declarations
> > > > >X-Sun-Charset: US-ASCII
> > > > >
> > > > >I am a bit confused here.
> > > > >
> > > > >On Pages 764 and 765, the grammar for Verilog 2000 is
> > > > >
> > > > >there is input_declaration in the function rules. And
> > input_declaration,
> > > > >output_declaration and inout_declaration in the task rules. So these
> > > rules
> > > > >will allow something like this...
> > > > >
> > > > >task t;
> > > > >input wire a;
> > > > >begin
> > > > >end
> > > > >endtask
> > > > >
> > > > >Interestingly the grammar doesn't allow this.
> > > > >
> > > > >task t(input a);
> > > > >wire a;
> > > > >begin
> > > > >end
> > > > >endtask
> > > > >
> > > > >Also the following is not allowed in the current language.
> > > > >Declaring a wire in a task is a syntax error.
> > > > >
> > > > >task t;
> > > > >input a;
> > > > >wire a;
> > > > >begin
> > > > >end
> > > > >endtask
> > > > >
> > > > >So shouldn't input_declaration for tasks/functions be replaced by just
> > > > >"input list_of_port_identifiers" and the same for
> > output_declaration and
> > > > >inout_declaration.
> > > > >
> > > > >Any comments?
> > > > >
> > > > >Thanks
> > > > >Dhiraj
> > > >
>
> ----- End Included Message -----
>
>
This archive was generated by hypermail 2.1.4
: Mon Jul 08 2002 - 12:54:15 PDT
and
sponsored by Boyd Technology, Inc.