<< Chapter < Page | Chapter >> Page > |
We've previously seen that SPIN knows some built-in concepts such as deadlock , livelock , weak- andstrong- fairness . We'll see in the next section that SPIN can also be used to verify any LTL formula. But first, let's characterize some of those built-inconcepts as LTL formulas using the context of a print server.
We will use the following propositions:
assert(!
)
).end
label).progress
label.
philosopher[3]@eating
''
is true when the fourth (0-indexed)
philosopher
process is at the label
eating
.For each of these problems, there are many equivalent formulas,some of which are easier to verify as equivalent than others.
np_
,
which corresponds to``all processes are in a non-progress state''.
When SPIN does its built-in check for non-progress cycles,it actually just verifying
!<>[]np_
.
You might
recall that SPIN's idea of progress
is state-based, not transition-based:SPIN (counterintuitively) considersit progress when a process does nothing but
squat in a
progress
state.
(This can only happen if weak fairness is not beingenforced, or a guard is being labeled as progress.)
How might we capture ``progress'' but stillpreclude those traces which just sit idly at a progress label?
We could add a second progress label immediately following
, call it
.
Similarly, we can introduce
.
Then we could verify that
.
(This assumes that all labels are private to each process.)Notification Switch
Would you like to follow the 'Model checking concurrent programs' conversation and receive update notifications?