User guide
6-10
VPD and EVCD File Generation
In order for VCS to provide memory data, it requires the +memcbk
switch.
VCS example:
vcs -R -I mda.v +memcbk
Memory declaration example:
reg [1:0] mem [3:0];
Examples
This section provides examples and graphical representations of
various MDA and memory declarations using the $vcdplusmemon
and $vcdplusmemoff tasks.
Example 6-1 MDA and Memory Declaration
Note that mem01 in this example is a three-dimensional array. It has
3x3x3 (27) locations; each location is 8 bits in length.
reg [3:0] addr1L, addr1R, addr2L, addr2R, addr3L, addr3R;
reg [7:0] mem01 [1:3] [4:6] [7:9]
See Figure 6-1 for an graphical representation of Example 6-1.