Subject: Re: [sv-bc] Separate Compilation Meeting Monday 6/9/03
From: Adam Krolnik (krolnik@lsil.com)
Date: Thu Jun 19 2003 - 08:00:41 PDT
Hi Randy;
Thanks for the clarification on the differences.
I too see that the differences between namespace and a module are minimal and would
rather see a module used. I wouln't mind an attribute as Jay suggested to ensure
it is not instantiated. Recall also that 1364-2001 configurations allow one to
specify which modules are 'top level' modules. Could one infer a rule
that a module specified as a top level module can not be instantiated.
I agree with Jay's experiences and statement that compilation order should not be
imposed. 1364-2001 already put configurations in place that should be sufficient
to describe the files necessary for systems. There are languages out there that
do fine without requiring the user to determine the best order for compilation.
You write that you expected import statements to only affect the next module. If
this is so, then why not place the import statements inside the modules like software
languages do. Clearly this simplifies the import requirements because the statement
is already in the proper scope. Having the statement outside a module would only
have value when it would apply to all modules of a given file.
For example, without namespaces, etc. we use an include file to contain standard
functions that designers use. For each module they want, they include the file
module foo (...);
`include "stdfunc.vh";
...
endmodule
I guess the real power of this proposal is:
1. The 'import' statement giving the user control over what names are brought
into their module.
2. The ability to import a signal from another module and give it a local name.
(like an alias as you mentioned.)
Anything other new abilities?
If we are proposing to allow people to specify which names come into their module,
should we allow a user to rename the element soas to not conflict with something else
they may have? I.e. consider what would happen if one needed to import functionality
from 2 sources and there is a name conflict. To use a Perl form:
use MyPkg1 {send_trans => pkg1_send_trans,
receive_trans => pkg1_receive_trans};
use MyPkg2 {send_trans => pkg2_send_trans,
receive_trans => pkg2_receive_trans};
Adam Krolnik
Verification Mgr.
LSI Logic Corp.
Plano TX. 75074
This archive was generated by hypermail 2b28 : Thu Jun 19 2003 - 08:03:35 PDT