Multithreading in SPIN model checker -


how parametrize spin model number of threads? using standard spin model checker. have options set number of parallel threads? checked reference didn't find useful

you can dynamically spawn promela process using run operator. can iterate as:

#define try_count 5 byte index = 0; :: index == try_count -> break :: else -> index++; run theprocess() od 

you can define file like:

active [try_count] proctype foo () {   printf ("pid: %d\n", _pid);   assert (true) }  init {   assert (true) } 

and run spin simulation:

$ spin -dtry_count=4 bar.pml               pid: 2       pid: 0           pid: 1                   pid: 3 5 processes created 

or verification

$ spin -dtry_count=4 -a bar.pml $ gcc -o bar pan.c $ ./bar hint: search more efficient if pan.c compiled -dsafety  (spin version 6.3.2 -- 17 may 2014)     + partial order reduction ... 

Comments

Popular posts from this blog

javascript - How to synchronize the Three.js and HTML/SVG coordinate systems (especially w.r.t. the y-axis)? -

javascript - How do I find how many occurences are there of a highlighted string, and which occurence is it? -

java - Reading data from multiple zip files and combining them to one -