Skip to main content

Improving swarming using genetic algorithms

Abstract

The verification of temporal properties against a given system may require the exploration of its full state space. In explicit model checking, this exploration uses a depth-first search and can be achieved with multiple randomized threads to increase performance. Nonetheless, the topology of the state space and the exploration order can cap the speedup up to a certain number of threads. This paper proposes a new technique that aims to tackle this limitation by generating artificial initial states, using genetic algorithms. Threads are then launched from these states and thus explore different parts of the state space. Our prototype implementation is 10% faster than state-of-the-art algorithms on a general benchmark and 40% on a specialized benchmark. Even if we expected a decrease in an order of magnitude, these results are still encouraging since they suggest a new way to handle existing limitations. Empirically, our technique seems well suited for “linear” topology, i.e., the one we can obtain when combining model checking algorithms with partial-order reduction techniques.

This is a preview of subscription content, access via your institution.

Fig. 1
Fig. 2
Fig. 3
Fig. 4
Fig. 5
Fig. 6
Fig. 7
Fig. 8
Fig. 9

Notes

  1. 1.

    It should be noted that even if DFS-based algorithms are hard to parallelize [31], they scale better in practice than parallelized breadth-first search (BFS) algorithms.

  2. 2.

    Sect. 6 for more details about the benchmark.

  3. 3.

    Notice that we use the C++ convention where visited.get(s) is written visited[s].

  4. 4.

    This particular case will certainly degrade performance due to contention over the shared hashmap.

  5. 5.

    Godefroid and Khurshid [15] do not generate states, but finite paths and their fitness functions analyze the whole paths to keep only those with few enabled transitions.

  6. 6.

    Main differences have been highlighted to help the reader.

  7. 7.

    Notice that mutation can be done ensuring that this variable will not be less than 1 and not be greater than 3.

  8. 8.

    Here, we only describe our approach on Büchi automata, but the adaptation for generalized Büchi automata is straightforward.

  9. 9.

    For a description of our setup, including selected models, detailed results and code, see http://www.lrde.epita.fr/~renault/benchs/ISSE-2020/results.html. All experiments can be replayed using either the Dockerfile available at https://github.com/etienne-renault/swarmedgp-docker or directly the Docker available at https://hub.docker.com/r/akaesus/swarmedgp. Also note that the archive of all our experiments has been published on Zenodo with (DOI): https://doi.org/10.5281/zenodo.3707234.

  10. 10.

    See http://fmt.cs.utwente.nl/tools/ltsmin/#divine for more details. Also note that we added some patches (available in the web page) to manage out-of-bound detection.

  11. 11.

    We evaluate other thresholds like 0.9999 or 0.99999, but it appears that augmenting the threshold does not increase performance, see the web page for more details.

  12. 12.

    dve2lts-mc –strategy=cndfs –threads=... -s 29 –perm=shift.

  13. 13.

    dve2lts-mc –strategy=ufscc –threads=... -s 29 –perm=shift.

  14. 14.

    dve2lts–sym –saturation=sat –order=bfs-prev -rf –lace-workers=... .

  15. 15.

    https://ltsmin.utwente.nl.

References

  1. 1.

    Ammann PE, Black PE, Majurski W (1998) Using model checking to generate tests from specications. In: ICFEM’98, vol 1687. IEEE, pp 46–54

  2. 2.

    Anderson RJ, Woll H (1994) Wait-free parallel algorithms for the union find problem. In: STOC’91, pp 370–380

  3. 3.

    Barnat J, Brim L, Ročkai P (2010) Scalable shared memory LTL model checking. Int J Softw Tools Technol Transf (STTT) 12(2):139–153

    Article  Google Scholar 

  4. 4.

    Barnat J, Ročkai P, Štill V, Weiser J (2015) Fast, dynamically-sized concurrent hash table. In: SPIN’15, vol 9232. of LNCS. Springer, pp 49–65

  5. 5.

    Bloemen V, van de Pol J (2016) Multi-core SCC-based LTL model checking, pp 18–33

  6. 6.

    Bloemen V, Laarman A, van de Pol J (2016) Multi-core on-the-y scc decomposition. In: PPOPP’16, vol 51, pp 8–20

  7. 7.

    Blom S, van de Pol J, Weber M (2009) Bridging the gap between enumerative and symbolic model checkers. Technical Report TR-CTIT-09–30, University of Twente, Enschede

  8. 8.

    Blom S, van de Pol J, Weber M (2010) LTSmin: distributed and symbolic reachability. In: CAV’10, pp 354–359

  9. 9.

    Burch JR, Clarke EM, McMillan KL, Dill DL, Hwang L (1990) Symbolic model checking: 1020 states and beyond. In: Proc. of the fifth annual IEEE symposium on logic in computer science. IEEE, pp 1–33

  10. 10.

    Clarke EM, Grumberg O, Peled DA (2000) Model checking. The MIT Press

  11. 11.

    Courcoubetis C, Vardi MY, Wolper P, Yannakakis M (1991) Memory-efficient algorithm for the verification of temporal properties. In: CAV’90, vol 531 of LNCS. Springer, pp 233–242

  12. 12.

    Duret-Lutz A, Lewkowicz A, Fauchille A, Michaud T, Renault E, Xu L (2016) Spot 2.0—a framework for LTL and \(\omega \)-automata manipulation. In: ATVA’16, vol 9938 of LNCS. Springer, pp 122–129

  13. 13.

    Evangelista S, Laarman A, Petrucci L, van de Pol J (2012) Improved multi-core nested depth-rst search. In: ATVA’12, vol 7561 of LNCS. Springer, pp 269–283

  14. 14.

    Garavel H, Mateescu R, Smarandache I (2001) Parallel state space construction for model-checking. Technical Report RR-4341, INRIA

  15. 15.

    Godefroid P, Khurshid S (2002) Exploring very large state spaces using genetic algorithms. In: TACAS’02. Springer, pp 266–280

  16. 16.

    Godefroid P, Holzmann GJ, Pirottin D (1992) State space caching revisited. In: CAV’92, vol 663 of LNCS. Springer, pp 178–191

  17. 17.

    Holland JH (1992) Genetic algorithms. Scientific American

  18. 18.

    Holzmann GJ (1987) On limits and possibilities of automated protocol analysis. In: PSTV’87. North-Holland, pp 339–344

  19. 19.

    Holzmann GJ, Bosnacki D (2007) The design of a multicore extension of the SPIN model checker. IEEE Trans Softw Eng 33(10):659–674

    Article  Google Scholar 

  20. 20.

    Holzmann GJ, Joshi R, Groce A (2011) Swarm verification techniques. IEEE Trans Softw Eng 37(6):845–857

    Article  Google Scholar 

  21. 21.

    Kant G, Laarman A, Meijer J, van de Pol J, Blom S, van Dijk T (2015) LTSmin: high-performance languageindependent model checking. In: TACAS’15, vol 9035. Springer, pp 692–707

  22. 22.

    Synthesis of parametric programs using genetic programming and model checking. In: INFINITY’13, vol 140, pp 70–84

  23. 23.

    Laarman A, van de Pol J, Weber M (2010) Boosting multi-core reachability performance with shared hash tables. In: FMCAD’10. IEEE, pp 247–256

  24. 24.

    Laarman A, Pater E, Van De Pol J, Hansen H (2016) Guardbased partial-order reduction. Int J Softw Tools Technol Transf (STTT) 7976:1–22

    Google Scholar 

  25. 25.

    Lamport L (1977) Proving the correctness of multiprocess programs. IEEE Trans Softw Eng 2:125–143

    Article  MathSciNet  Google Scholar 

  26. 26.

    Meijer J, Kant G, Blom S, van de Pol J (2014) Read, write and copy dependencies for symbolic model checking. In: Hardware and software: verification and testing–10th international Haifa verification conference (HVC’14) 2014 Proceedings 18–20, vol 8855 of LNCS. Haifa, Israel, pp 204–219

  27. 27.

    Pelánek R (2007) BEEM: benchmarks for explicit model checkers. In: SPIN’07, vol. 4595 of LNCS. Springer, pp 263–267

  28. 28.

    Pelánek R (2008) Properties of state spaces and their applications. Int J Softw Tools for Technol Transf (STTT) 10:443–454

    Article  Google Scholar 

  29. 29.

    Pelánek R, Hanžl T, vCerná I, Brim L (2005) Enhancing random walk state space exploration. In: FMICS’05. ACM Press, pp 98–105

  30. 30.

    Peled D (1994) Combining partial order reductions with on they model-checking. In: CAV’94, vol 818 of LNCS. Springer, pp 377–390

  31. 31.

    Reif JH (1985) Depth-rst search is inherently sequential. Inf Process Lett 20:229–234

    Article  Google Scholar 

  32. 32.

    Renault E (2018) Improving parallel state-space exploration using genetic algorithms. In: VECOS18, vol 11181 of LNCS. Springer, pp 133–149

  33. 33.

    Renault E, Duret-Lutz A, Kordon F, Poitrenaud D (2016) Variations on parallel explicit model checking for generalized Büchi automata. Int J Softw Tools Technol Transf (STTT), pp 1–21

  34. 34.

    Sivaraj H, Gopalakrishnan G (2003) Random walk based heuristic algorithms for distributed memory model checking. In: PDMC’03, vol 89, pp 51–67

  35. 35.

    Valmari A (1991) Stubborn sets for reduced state space generation. In: ICATPN’91, vol 618 of LNCS. Springer, pp 491–515

  36. 36.

    van Dijk J, van de Pol T (2017) Sylvan: multi-core framework for decision diagrams. Int J Softw Tools Technol Transf 19(6):675–696

    Article  Google Scholar 

  37. 37.

    van Dijk T, Meijer J, van de Pol J (2019) Multi-core on they saturation. In: TACAS’19, vol 11428 of LNCS. Springer, pp 58–75

  38. 38.

    Vardi MY (1996) An automata-theoretic approach to linear temporal logic. In: Ban’94, vol 1043 of LNCS. Springer, pp 238–266

Download references

Author information

Affiliations

Authors

Corresponding author

Correspondence to Etienne Renault.

Additional information

Publisher's Note

Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Rights and permissions

Reprints and Permissions

About this article

Verify currency and authenticity via CrossMark

Cite this article

Renault, E. Improving swarming using genetic algorithms. Innovations Syst Softw Eng 16, 143–159 (2020). https://doi.org/10.1007/s11334-020-00362-7

Download citation

Keywords

  • Model checking
  • Swarming
  • Genetic programming
  • Safety
  • Liveness