User guide

11-11
Race Detection
When you have two VCD files, find their differences with the vcdiff
utility. This utility is located in the vcs_install_dir/bin directory. The
command line for vcdiff is as follows:
vcdiff vcdfile1.dmp vcdfile2.dmp -options > output_filename
If you enter the vcdiff command without arguments, you see usage
information including the options.
Method 1: If the Number of Unique Race Conditions is Small
A unique race condition is a race condition that can occur several
times during simulation but only the first occurrence is reported in the
race.unique.out file. If there aren’t many lines in the race.unique.out
file than the number of unique race conditions is small. If so, for each
signal in the race.unique.out file:
1. Look in the output file from the vcdiff utility. If the signal values
are different, you have found a critical write-write race condition.
2. If the signal values are not different, look for the signals that are
assigned the value of this signal or assigned expressions that
include this signal (read operations).
3. If the values of these other signals are different at any point in the
two simulations, note the simulation times of these differences on
the other signals, and post process the race.out file looking for
race conditions in the first signal at around the simulation times
of the value differences on the other signals. Specify simulation
times just before and just after the time of these differences with
the -minmax option. Enter:
PostRace.pl -sig first_signal -minmax time time2
If the race.out.post file contains the first signal, then it is a critical
race condition and must be corrected.