Skip to content

Commit

Permalink
Improved the model by making ops log process local variable, fixed em…
Browse files Browse the repository at this point in the history
…pty writeset issue, also for excluded emptyset for read for faster model checking

Signed-off-by: Murat Demirbas <[email protected]>
  • Loading branch information
Murat Demirbas committed Aug 31, 2023
1 parent 897c904 commit a73562a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions specifications/KeyValueStore/KVsnap.tla
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ START: \* Start the transaction
tx := tx \union {self};
snapshotStore := store; \* take my snapshot of store

with (rk \in SUBSET Key; wk \in SUBSET Key \ { {} }) {
with (rk \in SUBSET Key \ { {} }; wk \in SUBSET Key \ { {} }) {
read_keys := rk; \* select a random read-key-set from possible read-keys
write_keys := wk; \* select a random write-key-set from possible write-keys
};
Expand Down Expand Up @@ -79,7 +79,7 @@ COMMIT: \* Commit the transaction to the database if there is no conflict
}
*)

\* BEGIN TRANSLATION (chksum(pcal) = "15348ab3" /\ chksum(tla) = "7613a888")
\* BEGIN TRANSLATION (chksum(pcal) = "1adfcb46" /\ chksum(tla) = "5b28617f")
VARIABLES store, tx, missed, pc, snapshotStore, read_keys, write_keys, ops

vars == << store, tx, missed, pc, snapshotStore, read_keys, write_keys, ops
Expand All @@ -101,7 +101,7 @@ Init == (* Global variables *)
START(self) == /\ pc[self] = "START"
/\ tx' = (tx \union {self})
/\ snapshotStore' = [snapshotStore EXCEPT ![self] = store]
/\ \E rk \in SUBSET Key:
/\ \E rk \in SUBSET Key \ { {} }:
\E wk \in SUBSET Key \ { {} }:
/\ read_keys' = [read_keys EXCEPT ![self] = rk]
/\ write_keys' = [write_keys EXCEPT ![self] = wk]
Expand Down

0 comments on commit a73562a

Please sign in to comment.