A
Allan Herriman
Guest
Hi,
In this paper,
http://www.sunburst-design.com/papers/CummingsHDLCON2002_Parameters_rev1_2.pdf
Cliff Cummings says "The `timescale directive can have a huge impact
on the performance of most Verilog simulators." He goes on to say
that "adding a 1ps precision to a model that is adequately modeled
using either 1ns or 100ps time_precisions can increase simulation time
by more than 100% and simulation memory usage by more than 150%."
I thought that HDL simulators are discrete event based, and time jumps
from one set of scheduled events to the next.
This jump just adds an integer to the current time. The size of the
integer (e.g. 1 ns vs 1000 ps) being added shouldn't make a difference
to the (real) time taken to perform the addition.
What then, is the mechanism for the slowdown that Cliff observed?
Is it that the coarser precision has the effect of reducing the number
of events?
E.g.
I have signals scheduled to change at 1 ps, 3 ps, 15 ps and 33 ps
(which requires 4 "jumps")
Changing from 1 ps to 10 ps precision turns these into 0 ps, 0 ps, 10
ps and 30 ps (which requires 2 "jumps", a saving of 2 "jumps").
.... but this makes the simulation faster by changing the semantics of
the simulation, which sounds like cheating!
Is there another reason for the slowdown?
Thanks,
Allan.
In this paper,
http://www.sunburst-design.com/papers/CummingsHDLCON2002_Parameters_rev1_2.pdf
Cliff Cummings says "The `timescale directive can have a huge impact
on the performance of most Verilog simulators." He goes on to say
that "adding a 1ps precision to a model that is adequately modeled
using either 1ns or 100ps time_precisions can increase simulation time
by more than 100% and simulation memory usage by more than 150%."
I thought that HDL simulators are discrete event based, and time jumps
from one set of scheduled events to the next.
This jump just adds an integer to the current time. The size of the
integer (e.g. 1 ns vs 1000 ps) being added shouldn't make a difference
to the (real) time taken to perform the addition.
What then, is the mechanism for the slowdown that Cliff observed?
Is it that the coarser precision has the effect of reducing the number
of events?
E.g.
I have signals scheduled to change at 1 ps, 3 ps, 15 ps and 33 ps
(which requires 4 "jumps")
Changing from 1 ps to 10 ps precision turns these into 0 ps, 0 ps, 10
ps and 30 ps (which requires 2 "jumps", a saving of 2 "jumps").
.... but this makes the simulation faster by changing the semantics of
the simulation, which sounds like cheating!
Is there another reason for the slowdown?
Thanks,
Allan.