This page introduces the concept of a consistent cut of a dataflow graph. This concept is the basis of global snapshot algorithms and algorithms that detect deadlock and termination
A computation is a sequence of states where there exists a transition from each state in the sequence to the next. A computation can be specified as a sequence of steps, including initialization and finalization steps, as described in the page on data flow. A cut of a computation is a partition of the steps of the computation into subsets past and future.
past
are from steps in
past
.
Equivalent definitions of a consistent cut are:
future
steps to past
steps.
past
steps are
from past
steps.
future
steps are
to future
steps.
A cut of a dataflow graph is an instance of a cut of a flow network.
The top diagram of figure 1 shows a consistent cut in which vertices in
past
are
colored red and vertices in future
are green.
The curved black line is the boundary separating past
from future
.
Let \(E\) be a computation and let (past, future)
be any
consistent cut of the computation.
There exists a computation \(E'\), which is a permutation of \(E\), in
which all steps in past
are executed before
all steps in future.
Proof
Let pre
be the sequence of steps obtained from \(E\) by
retaining only steps in past
and deleting steps in
future
.
Let post
be the sequence of steps obtained from \(E\) by
retaining only steps in future
and deleting steps in
past
.
Let \(E'\) be the sequence consisting of pre
followed by
post
.
The proof that \(E'\) is a topological sort is straightforward. Therefore, \(E'\) is also a computation.
Let (past, future)
be a consistent cut of a computation \(E\).
Let pre
and past
be sequences of steps
defined in the previous paragraph.
The sequence of steps consisting of pre
followed by
post
is a computation.
The state at the consistent cut (past, future)
is defined as
as the state after computation pre
and before
post
.
The state at a consistent cut (past, future)
of a
computation \(E\)
is given by labels of the edges from past
to future
in the
dataflow graph of \(E\).
The state of an agent X
at the cut
is given by the label of the agent edge for
X
from a step in the past
to a step in the
future
.
The state of a channel at the cut is the sequence of messages sent on
the channel in the past
and received in the
future
.
Pictorially, the state S*
at a consistent cut
(past, future)
is given by the labels of edges that cross
the boundary separating past
from future
.
In the upper diagram of figure 1, these are are the edges that cross
the curved black line.
K. Mani Chandy, Emeritus Simon Ramo Professor, California Institute of Technology