Changes between Version 15 and Version 16 of ContractReduction


Ignore:
Timestamp:
07/21/14 15:55:41 (12 years ago)
Author:
siegel
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • ContractReduction

    v15 v16  
    4848== Ample set and the exact interpretation of $depends ==
    4949
    50 Fix a state s, a process q, and a statement S.
     50Fix a statement S and a process q.
    5151
    52 Let T(s,S,q) denote the set of transitions specified by having q execute S from s.  We say this is a set because some statements S are nondeterministic, meaning they can generate multiple transitions. Note that T(s,S,q) includes all transitions specified by S, even those that are not enabled.
     52Let T(S,q) denote the set of transitions specified by having q execute S.  We say this is a set because some statements S are nondeterministic, meaning they can generate multiple transitions.  Note that T(S,q) is independent of the state.  In particular, it must include all possible transitions that could be generated by S, even if not all of them are enabled in every state.
     53
     54Now fix a state s and assume that the origin of S is the location of q in s.
    5355
    5456Suppose A(s,S,q) is a set of procs which satisfies the following:
    5557
    56 In any execution departing from s, no transition dependent on a transition in T(s,S,q) can occur without a transition from a proc in A(s,S,q) occurring first.
     58In any execution departing from s, no transition dependent on a transition in T(S,q) can occur without a transition from a proc in A(s,S,q) occurring first.
    5759
    5860Then define AMPLE as follows:
     
    6567    choose q in WorkSet;
    6668    WorkSet := WorkSet - {q};
    67     forall statements S emanating from current location of q in s:
     69    forall statements S with origin the location of q in s:
    6870      foreach r in A(s,S,q): if r is not in AmpleProcs, add r to AmpleProcs and to WorkSet
    6971    end forall;
     
    7375}}}
    7476
    75 Claim: for any process p, if AMPLE(s,p) contains a process with at least one enabled transition in s, then it defines an ample set, i.e., from any execution departing from s, no transition dependent
     77Claim: for any process p, if AMPLE(s,p) contains a process with at least one enabled transition in s,
     78then it defines an ample set, i.e., from any execution departing from s, no transition dependent
    7679on a transition from a proc in AMPLE(s,p) can occur without a transition from a proc in AMPLE(s,p) occurring first.
    7780
     
    8386be any execution prefix starting from s for which t is dependent on a transition from a proc in AMPLE.
    8487
    85 ASSUME that none of the t_i are from procs in AMPLE.
     88ASSUME that none of the t_i are from procs in AMPLE.  We aim to get a contradiction.
    8689
    87 Say t is dependent on transition t0, and that t0 has statement S0 in process q0, and q0 is in AMPLE.
     90Say t is dependent on transition t0 in T(S0,q0), for some statement S0 and process q0 in AMPLE.
    8891
    89 Throughout the entire execution prefix (E), q0 remains at the location it had in state s.  In particular, S0 emanates
    90 from the current location of q0 in s.
     92By assumption, throughout the entire execution prefix (E), q0 remains at the location it had in state s.
     93In particular, the origin of S0 is the location of q0 in s.
    9194
    92 Since q0 is in AMPLE, that means from the algorithm that defines AMPLE that we must
    93 have A(s,S0,q0) is a subset of AMPLE.
     95Since q0 is in AMPLE, it follows from the algorithm that defines AMPLE that A(s,S0,q0) is a subset of AMPLE.
    9496
    95 From the contract defining A, we know that no transition dependent on a transition in T(s,S0,q0) can occur without a transition
    96 from a proc in A(s,S0,q0) occurring first.  Hence for some i, t_i is from a proc in A(s,S0,q0), and therefore t_i is in AMPLE.
    97 
    98 We conclude that no transition dependent on a transition from a proc in AMPLE can occur without a transition from a proc
    99 in AMPLE occurring first.  QED.
     97From the contract defining A, we know that no transition dependent on a transition in T(S0,q0) can occur without a transition
     98from a proc in A(s,S0,q0) occurring first.  Hence for some i, t_i is from a proc in A(s,S0,q0), and therefore t_i is in AMPLE,
     99contradicting the ASSUMPTION.  QED.
    100100
    101101