[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [tlaplus] synchronization using a component



Dear Marko,

May I suggest you make the following modifications to the Synchronizer spec?

1- Change the name "Init" to a more specific name, such as "TSInit" which stands for ThreadSyncInit.

2- Define a next state relation.

3- Define the complete spec in the following form:
TSSpec ==
/\ TSInit
/\ [][TSNext]_<<threadAWaiting, threadBWaiting>>

4- Define an invariant of the new spec, after all we need to know what is the correctness condition of this specification!
Adding this invariant will allow you to check the correctness of your specification by running the TLC model checker.

5- Add descriptive comments to each part of the spec, for example:
(***************************************************************************)
(* An explanation of the action                                            *)
(***************************************************************************)
waitingForB(threadAVars) ==
  threadAWaiting
    => UNCHANGED threadAVars


Best Regards,
AmirHossein


On Wed, Jun 12, 2019 at 10:38 PM 'Marko Schuetz-Schmuck' via tlaplus <tlaplus@xxxxxxxxxxxxxxxx> wrote:
Dear All,

I found it interesting that with TLA+ I can have a component that is
responsible of synchronizing the representations of two
threads. https://github.com/MarkoSchuetz/synchronizer

Best regards,

Marko

--
You received this message because you are subscribed to the Google Groups "tlaplus" group.
To unsubscribe from this group and stop receiving emails from it, send an email to tlaplus+unsubscribe@xxxxxxxxxxxxxxxx.
To post to this group, send email to tlaplus@xxxxxxxxxxxxxxxx.
Visit this group at https://groups.google.com/group/tlaplus.
To view this discussion on the web visit https://groups.google.com/d/msgid/tlaplus/87ef3y1xsk.fsf%40tpad-m.i-did-not-set--mail-host-address--so-tickle-me.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "tlaplus" group.
To unsubscribe from this group and stop receiving emails from it, send an email to tlaplus+unsubscribe@xxxxxxxxxxxxxxxx.
To post to this group, send email to tlaplus@xxxxxxxxxxxxxxxx.
Visit this group at https://groups.google.com/group/tlaplus.
To view this discussion on the web visit https://groups.google.com/d/msgid/tlaplus/CAKxfy0t93-T8dAs1omWT%3DmeKeJ5XYk5eHQVMweAxNA%3DKU2ZDRQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.