Technical data
How to use checkpoint/restore
ModelSim EE/PLUS Reference Manual Tips and Techniques
-
531
The checkpoint file is normally compressed. If there is a need to turn off the
compression, you can do so by setting a special Tcl variable. Use:
set CheckpointCompressMode 0
to turn compression off, and turn compression back on with:
set CheckpointCompressMode 1
You can also control checkpoint compression using the
modelsim.ini
file in the
VSIM section (use the same 0 or 1 switch):
[vsim]
CheckpointCompressMode = <switch>
If you use the foreign interface, you will need to add additional function calls in
order to use
checkpoint/restore
. See "Using checkpoint/restore with the FLI"
(p463) for more information.
The difference between checkpoint/restore and restartin
g
The
restart
(p356) command resets the simulator to time zero, clears out any
logged waveforms, and closes any files opened under VHDL and the Verilog
$fopen system task. You can get the same effect by first doing a checkpoint at time
zero and later doing a restore. But with
restart
you don't have to save the
checkpoint and the
restart
is likely to be faster. But when you need to set the state
to anything other than time zero, you will need to use
checkpoint/restore
.
Usin
g
macros with restart and checkpoint/restore
The
restart
(p356) command resets and restarts the simulation kernel, and zeros
out any user-defined commands, but it does not touch the state of the macro
interpreter. This lets you do
restart
commands within macros.
The pause mode indicates that a macro has been interrupted. That condition will
not be affected by a restart, and if the restart is done with an interrupted macro, the
macro will still be interrupted after the restart.
The situation is similar for using
checkpoint/restore
without quitting VSIM, that
is, doing a
checkpoint
(p291) and later in the same session doing a
restore
(p357)
of the earlier checkpoint. The
restore
does not touch the state of the macro
interpreter so you may also do
checkpoint
and
restore
commands within macros.