[Imprint][Data Privacy Statement][E-Mail]

Back to main index. View the specification. View theorem base summary, View theorem base listing, the used properties by spec, the dependency list, the symbol table,

Specification TMS2OP
enrich
   TMS2state, 
   abs-old
with
   functions 
       . ⊕ . : (L → V) × Rwset → L → V;
       TMS2stepf : TMS2state × TMS2action → TMS2state;
   
   predicates 
       TMS2start : TMS2state;
       TMS2stepp : TMS2state × TMS2action;
       TMS2step : TMS2state × TMS2action × TMS2state;
       TMS2astep : TMS2state × TMS2absaction × TMS2state;
       validIdx : T × Nat × TMS2state;
       ∃valid : Nat × Rwset × Memlist;
       DoRead : TMS2state × T × TMS2state;
       . ⊆ . : Rwset × (L → V);
   
   variables 
       rdset : Rwset;
       wrset : Rwset;
       beginIdx : Nat;
       st : TMS2state;
       st' : TMS2state;
       mem : L → V;
       l : L;
       v : V;
   
   
   axioms 
      TMS2astep-def: TMS2astep(st, aa, st') ↔ (∃ a. abs(a) = aa ∧ TMS2step(st, a, st'));
      used for: s, ls;
      
      TMS2step-def: TMS2step(st, a, st') ↔ (∃ t. a = DoRead(t) ⊃ DoRead(st, a.t, st');TMS2stepp(st, a) ∧ st' = TMS2stepf(st, a));
      used for: s, ls;
      
      subset-base: ∅ ⊆ mem;
      used for: s, ls;
      
      subset-rec: ¬ l ∈ rws → (rws[l := v] ⊆ mem ↔ mem(l) = v ∧ rws ⊆ mem);
      used for: s, ls;
      
      startf-def: TMS2start(st) ↔ st.memories = ∅ ' ∧ (∀ t. st.apcf(t) = notStarted ∧ st.rdsetf(t) = ∅ ∧ st.wrsetf(t) = ∅ ∧ st.beginIdxf(t) = 0);
      used for: s, ls;
      
      TMS2stepp-invbegin: TMS2stepp(st, invTMBegin(t)) ↔ st.apcf(t) = notStarted;
      used for: s, ls;
      
      TMS2stepf-invbegin: TMS2stepf(st, invTMBegin(t)) = (st.apcf:= st.apcf(t := beginPending)).beginIdxf:= st.beginIdxf(t := # st.memories - 1);
      used for: s, ls;
      
      TMS2stepp-invwrite: TMS2stepp(st, invTMWrite(t, l, v)) ↔ st.apcf(t) = ready;
      used for: s, ls;
      
      TMS2stepf-invwrite: TMS2stepf(st, invTMWrite(t, l, v)) = st.apcf:= st.apcf(t := doWrite(l, v));
      used for: s, ls;
      
      TMS2stepp-invread: TMS2stepp(st, invTMRead(t, l)) ↔ st.apcf(t) = ready;
      used for: s, ls;
      
      TMS2stepf-invread: TMS2stepf(st, invTMRead(t, l)) = st.apcf:= st.apcf(t := doRead(l));
      used for: s, ls;
      
      TMS2stepp-invend: TMS2stepp(st, invTMEnd(t)) ↔ st.apcf(t) = ready;
      used for: s, ls;
      
      TMS2step-invend: TMS2stepf(st, invTMEnd(t)) = st.apcf:= st.apcf(t := doCommit);
      used for: s, ls;
      
      TMS2stepp-invcancel: TMS2stepp(st, invcancel(t)) ↔ st.apcf(t) = ready;
      used for: s, ls;
      
      TMS2stepf-invcancel: TMS2stepf(st, invcancel(t)) = st.apcf:= st.apcf(t := cancelPending);
      used for: s, ls;
      
      TMS2stepp-retbegin: TMS2stepp(st, respTMBegin(t)) ↔ st.apcf(t) = beginPending;
      used for: s, ls;
      
      TMS2stepf-retbegin: TMS2stepf(st, respTMBegin(t)) = st.apcf:= st.apcf(t := ready);
      used for: s, ls;
      
      TMS2stepp-retread: TMS2stepp(st, respTMRead(t, v)) ↔ st.apcf(t) = readResp(v);
      used for: s, ls;
      
      TMS2stepf-retread: TMS2stepf(st, respTMRead(t, v)) = st.apcf:= st.apcf(t := ready);
      used for: s, ls;
      
      TMS2stepp-retwrite: TMS2stepp(st, respTMWrite(t)) ↔ st.apcf(t) = writeResp;
      used for: s, ls;
      
      TMS2step-retwrite: TMS2stepf(st, respTMWrite(t)) = st.apcf:= st.apcf(t := ready);
      used for: s, ls;
      
      TMS2stepp-retend: TMS2stepp(st, respTMEnd(t)) ↔ st.apcf(t) = commitResp;
      used for: s, ls;
      
      TMS2step-retend: TMS2stepf(st, respTMEnd(t)) = st.apcf:= st.apcf(t := committed);
      used for: s, ls;
      
      TMS2stepp-retabort: 
        TMS2stepp(st, respabort(t))
      ↔ ¬(st.apcf(t) = notStarted ∨ st.apcf(t) = ready ∨ st.apcf(t) = commitResp ∨ st.apcf(t) = committed ∨ st.apcf(t) = aborted);
      used for: s, ls;
      
      TMS2stepf-retabort: TMS2stepf(st, respabort(t)) = st.apcf:= st.apcf(t := aborted);
      used for: s, ls;
      
      TMS2stepp-DoCommitReadonly: 
      TMS2stepp(st, DoCommitReadOnly(t)) ↔ ¬ ¬(st.apcf(t) = doCommit ∧ st.wrsetf(t) = ∅ ∧ ∃valid(st.beginIdxf(t), st.rdsetf(t), st.memories));
      used for: s, ls;
      
      TMS2stepf-DoCommitReadonly: TMS2stepf(st, DoCommitReadOnly(t)) = st.apcf:= st.apcf(t := commitResp);
      used for: s, ls;
      
      TMS2stepp-DoCommitWriter: TMS2stepp(st, DoCommitWriter(t)) ↔ ¬ ¬(st.apcf(t) = doCommit ∧ st.rdsetf(t) ⊆ st.memories.last);
      used for: s, ls;
      
      TMS2stepf-DoCommitWriter: 
      TMS2stepf(st, DoCommitWriter(t)) = (st.apcf:= st.apcf(t := commitResp)).memories:= (st.memories + (st.memories.last ⊕ st.wrsetf(t)));
      used for: s, ls;
      
      DoRead-def: 
        DoRead(st, t, st')
      ↔ (∃ l. 
             st.apcf(t) = doRead(l)
           ∧ (  l ∈ st.wrsetf(t) ∧ st' = st.apcf:= st.apcf(t := readResp(st.wrsetf(t)[l]))
              ∨ (∃ n. 
                     validIdx(t, n, st)
                   ∧ st' = (st.apcf:= st.apcf(t := readResp(st.memories[n](l)))).rdsetf:= st.rdsetf(t := st.rdsetf(t)[l := st.memories[n](l)]))));
      
      TMS2stepp-tau: ¬ TMS2stepp(st, τ);
      used for: s, ls;
      
      TMS2stepp-DoWrite: TMS2stepp(st, DoWrite(t)) ↔ (∃ l, v. st.apcf(t) = doWrite(l, v));
      used for: s, ls;
      
      TMS2stepf-DoWrite: 
      TMS2stepf(st, DoWrite(t)) = (st.apcf:= st.apcf(t := writeResp)).wrsetf:= st.wrsetf(t := st.wrsetf(t)[st.apcf(t).l := st.apcf(t).v]);
      used for: s, ls;
      
      overwrite-def: ((mem ⊕ rws))(l) = (l ∈ rws ⊃ rws[l];mem(l));
      used for: s, ls;
      
      validIdx-def: validIdx(t, n, st) ↔ ¬ ¬(st.beginIdxf(t) ≤ n ∧ n < # st.memories ∧ st.rdsetf(t) ⊆ st.memories[n]);
      used for: s, ls;
      
      exvalid-def: ∃valid(beginIdx, rdset, memories) ↔ (∃ n. beginIdx ≤ n ∧ n < # memories ∧ rdset ⊆ memories[n]);
      used for: ls;
   
   
end enrich