File: README.txt

package info (click to toggle)
systemc 3.0.2-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 41,768 kB
  • sloc: cpp: 181,958; sh: 4,925; asm: 2,700; perl: 1,980; ansic: 1,931; makefile: 1,761; fortran: 492; python: 482; awk: 157; csh: 50
file content (54 lines) | stat: -rw-r--r-- 2,117 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
The sc_export class is an addition to ports and allow one to export an
interface through the module hierarchy. The sc_export makes an
interface - that is bound to a channel located somewhere within that
module - available to the outside of the module. If you see a module with an 
sc_export instance then you can be sure that this module already has a channel 
bound to that sc_export.


Binding
---

sc_export instances are similar to ports with respect to binding. An
sc_export can be bound to either a channel or another sc_export,
given that this sc_export itself is directly or indirectly
bound to a channel. Types must match which is checked either 
during compilation or elaboration

Binding can be done by name, or by CTOR. Binding is
generally done just like ports, except for the following:

If you bind an sc_export to another sc_export like port
E.IFP2 to D.IFP in the example below, then you must bind the
parent_expp to the child_exp, e.g. "parent_exp(child_exp)". For ports,
this is done the opposite way like child_port(parent_port),
however this is wrong for sc_exports and leads to an error during
elaboration.

As a rule of thumb, bind "further(closer)" with "further" the
port/export that is further away from the channel. This
further(closer) rule works for ports as well as exports. For
hierarchical ports, the channel is connected to the port of the
top-most module, so parent_port==closer, hence do a
child_port(parent_port). For an sc_export, the channel is
embedded to the innermost instance, so child_exp==closer, hence do
parent_exp(child_exp)

Names
---

An sc_export can be given an explicit name through the CTOR. If
not, then a default name like "export_0", "export_1", ... is given
with an individual number set for each module.


Supported Functions and Restrictions
---

You can access the interface of an export with the get_interface()
method as well as with operator ->.

It is not allowed to use an export as an argument in the sensitivity
list of a process. Furthermore, exports are not allowed in lambda
expressions. Processes can use ports but not exports in these
contexts.