next up previous
Next: Commentary Up: No Title Previous: No Title

Combining State Machines

We first model each process as a (sequential) state machine. Thus, we have tex2html_wrap_inline808 and tex2html_wrap_inline810 . The question is ``What is an appropriate state machine model for P || Q?'' Before we answer this question, reconsider the example above, where we have (fortuitously) the simpler case that tex2html_wrap_inline814 = tex2html_wrap_inline816 . You might like a property likegif:

tex2html_wrap_inline818

but that's clearly not true here! That is, there exists a trace in traces(P || Q) that is not even in traces(P) or traces(Q).

What's going on?

  1. We need to divide the state variables, tex2html_wrap_inline826 , of each process, tex2html_wrap_inline828 , into locals and globals. The locals are those that are affected by only that process; the globals are those that are shared with all other processes and can be changed by any of them.
  2. For each process, P, we need to add its program counter, tex2html_wrap_inline832 , to its set of locals.

Note that we are assuming each state is a mapping from variables to values; here, tex2html_wrap_inline826 is the same set as Var in Handout on State Machine Basics for one machine. Since we have more than one process, we need to distinguish between the different variable sets. For simplicity, however, we will assume the same value set, Val, over which all the different types of variables range.

In what follows, to simplify the notation, for state s and variable set V, I'll write tex2html_wrap_inline844 to stand for tex2html_wrap_inline846 (restriction of the domain of state s to just the variables in V). I'll also write V = V' to stand for tex2html_wrap_inline854 (all variables in V stay the same in value).

Now we can define tex2html_wrap_inline858 as follows:

tex2html_wrap908


next up previous
Next: Commentary Up: No Title Previous: No Title

Norman Papernick
Mon Mar 18 11:52:59 EST 1996