Section 13.4 - Modports issues (Stuart/Cadence) [Basic, System]
- allow modports to be declared outside of interface/module, for reuse
- allow (modules and) interfaces to specify which modport(s) they implement
- import/export is confusing and unnecessary
It appears that Modports can only be declared within an interface.
Why not allow modports to be declared outside of interfaces and modules, so that more than one interface implementation can implement the same modport?
This would be a less error-prone solution than "generic interfaces".
The use of "import/export" within Modports is confusing and unnecessary.
Instead I believe that modports should be declared separately from interfaces, and the tasks that a modport makes available should be declared within the modport.
Then when an interface is to implement the tasks of a modport, it explicitly indicates this via a "implements mod_port_name" construct.
Similarly, since I believe that modules and interfaces should be equivalent, a module that wishes to make tasks available to other modules or interfaces will simply specify that it "implements some_mod_port_name".
Modules and interfaces should be able to implement multiple modports.
Of these two items, we are transferring the need to have both private and public variables for an interface to the Enhancement committee
We are also transferring the need for modports to be independent of interfaces (i.e. outside them). The idea is inheriteance of abstract base classes; separating the definition of an interface and the implementation of an interface.