Hardware Reference
In-Depth Information
10
20
30
40
50
60
70
80
90
100
clk1
a
clk2
b
Fig. 12.12
Waveform for assertions
a13
and
a14
of module
m3
flows to
nexttime
, and so the
nexttime
causes advance to the next occurrence
of
posedge
clk1
strictly after t
0
before looking for a concurrent or subsequent
occurrence of
posedge
clk2
at which to evaluate
b
.In
a14
,
##1
is a synchronizer
between the occurrence of
posedge
clk1
at t
0
and the earliest strictly subsequent
occurrence of
posedge
clk2
, where it evaluates
b
.
This difference is illustrated in the waveform of Fig.
12.12
. The solid arrows
represent evaluations of
a13
, while the dashed arrows represent evaluations of
a14
.
The evaluation attempt of
a13
beginning at time 20 matches the antecedent of
|->
at time 20 and then advances to time 40 because of the
nexttime
clocked
by
posedge
clk1
. At time 40, the attempt begins looking for the next concurrent
or future occurrence of
posedge
clk2
, which is at time 65. At time 65, the sampled
value of
b
is checked and found to be
1'b1
, so the overall evaluation passes. The
evaluation of
a14
beginning at time 20 behaves differently. After matching the
antecedent of
|->
at time 20, the synchronizer
##1
causes this evaluation to begin
looking for the next strictly future occurrence of
posedge
clk2
, which is at time 35.
At time 35, the evaluation checks
b
and fails. The evaluation of
a13
beginning at
time 60 advances to time 80 due to the
nexttime
. Since
posedge
clk2
also occurs
at time 80,
b
is checked at this time, and the evaluation fails. Again, the evaluation of
a14
beginning at time 60 behaves differently. This evaluation finds the next strictly
future occurrence of
posedge
clk2
at time 65, checks
b
there, and passes.
The structure of
a13
ensures that evaluation of
nexttime
always begins in a
time step in which
posedge
clk1
occurs and therefore is already
aligned
to the
governing (i.e., incoming) clock for
nexttime
. It is possible to use
nexttime
as
a synchronizer in a way that need not start in a time step aligned to its governing
clock. In such a case,
nexttime
specifies both of the following temporal actions:
12
12
It may seem strange that
nexttime
specifies both alignment and advancement to the next
tick. This behavior is aligned with PSL and is needed in order for the behavior of
nexttime
as a synchronizer to converge to the singly clocked behavior of
nexttime
under certain clock
convergence scenarios. See Sect.
12.2.5.3
and Exercise
12.5
.
Search WWH ::
Custom Search