Table of Contents

1. Generating interactive VCD traces

1. Generating interactive VCD traces

the --trace option can be used to generated online VCD traces at simulation time. These traces can be redirected to gtkwave to gather information while the application is simulated. This feature can very very helpfull while being used in interactive debug mode with GDB

The followinf lines can be used to create a named pipe (FIFO) within the filesystem. This pipe is then used a source of VCD traces for GTKWave (shmidcat is a tool included in GTKWare distribution). The vcd:pipe option will force wsim to directly generate VCD traces that will be written to the file names pipe.

	shell$ mkfifo pipe
        shell$ cat pipe | shmidcat  | gtkwave -v -I whatever.sav 
	shell$ wsim-platform --trace=vcd:pipe [args]

Using this mode of traces generation, when coupled with GDB, can save a full history of software variables while debuging. Some buffering effect may appear while writing data. To decrease or increase the buffer size used to output events an extra argument can be given on the command line --trace=vcd:pipe:size. A buffer size of 1 will directly output events as soon as they are produced but might represent a significant performance hit depending on the way the interactive information is used.