Skip to main content
Erschienen in: Innovations in Systems and Software Engineering 1/2016

19.12.2015 | Original Paper

From verified model to executable program: the PAT approach

verfasst von: Huiquan Zhu, Jing Sun, Jin Song Dong, Shang-Wei Lin

Erschienen in: Innovations in Systems and Software Engineering | Ausgabe 1/2016

Einloggen

Aktivieren Sie unsere intelligente Suche, um passende Fachinhalte oder Patente zu finden.

search-config
loading …

Abstract

CSP# is a formal modeling language that emphasizes the design of communication in concurrent systems. PAT framework provides a model checking environment for the simulation and verification of CSP# models. Although the desired properties can be formally verified at the design level, it is not always straightforward to ensure the correctness of the system’s implementation conforms to the behaviors of the formal design model. To avoid human error and enhance productivity, it would be beneficial to have a tool support to automatically generate the executable programs from their corresponding formal models. In this paper, we propose such a solution for translating verified CSP# models into C# programs in the PAT framework. We encoded the CSP# operators in a C# library-“PAT.Runtime”, where the event synchronization is based on the “Monitor” class in C#. The precondition and choice layers are built on top of the CSP event synchronization to support language-specific features. We further developed a code generation tool to automatically transform CSP# models into multi-threaded C# programs. We proved that the generated C# program and original CSP# model are equivalent on the trace semantics. This equivalence guarantees that the verified properties of the CSP# models are preserved in the generated C# programs. Furthermore, based on the existing implementation of choice operator, we improved the synchronization mechanism by pruning the unnecessary communications among the choice operators. The experiment results showed that the improved mechanism notably outperforms the standard JCSP library.

Sie haben noch keine Lizenz? Dann Informieren Sie sich jetzt über unsere Produkte:

Springer Professional "Wirtschaft+Technik"

Online-Abonnement

Mit Springer Professional "Wirtschaft+Technik" erhalten Sie Zugriff auf:

  • über 102.000 Bücher
  • über 537 Zeitschriften

aus folgenden Fachgebieten:

  • Automobil + Motoren
  • Bauwesen + Immobilien
  • Business IT + Informatik
  • Elektrotechnik + Elektronik
  • Energie + Nachhaltigkeit
  • Finance + Banking
  • Management + Führung
  • Marketing + Vertrieb
  • Maschinenbau + Werkstoffe
  • Versicherung + Risiko

Jetzt Wissensvorsprung sichern!

Springer Professional "Wirtschaft"

Online-Abonnement

Mit Springer Professional "Wirtschaft" erhalten Sie Zugriff auf:

  • über 67.000 Bücher
  • über 340 Zeitschriften

aus folgenden Fachgebieten:

  • Bauwesen + Immobilien
  • Business IT + Informatik
  • Finance + Banking
  • Management + Führung
  • Marketing + Vertrieb
  • Versicherung + Risiko




Jetzt Wissensvorsprung sichern!

Springer Professional "Technik"

Online-Abonnement

Mit Springer Professional "Technik" erhalten Sie Zugriff auf:

  • über 67.000 Bücher
  • über 390 Zeitschriften

aus folgenden Fachgebieten:

  • Automobil + Motoren
  • Bauwesen + Immobilien
  • Business IT + Informatik
  • Elektrotechnik + Elektronik
  • Energie + Nachhaltigkeit
  • Maschinenbau + Werkstoffe




 

Jetzt Wissensvorsprung sichern!

Fußnoten
1
i.e., the thread running the choice operator is the nth thread to synchronize on the event object that require n threads to synchronize.
 
Literatur
1.
Zurück zum Zitat Baier C, Katoen J (2008) Principles of model checking. The MIT Press, CambridgeMATH Baier C, Katoen J (2008) Principles of model checking. The MIT Press, CambridgeMATH
2.
Zurück zum Zitat Bjørndalen JM, Vinter B, Anshus OJ (2007) PyCSP—communicating sequential processes for python. In: McEwan AA, Schneider SA, Ifill W, Welch PH (eds) The 30th communicating process architectures conference (CPA’07), pp 229–248 Bjørndalen JM, Vinter B, Anshus OJ (2007) PyCSP—communicating sequential processes for python. In: McEwan AA, Schneider SA, Ifill W, Welch PH (eds) The 30th communicating process architectures conference (CPA’07), pp 229–248
3.
Zurück zum Zitat Brown N (2007) C++CSP2: a many-to-many threading model for multicore architectures. In: Communicating process architectures 2007: WoTUG-30, pp 183–205 Brown N (2007) C++CSP2: a many-to-many threading model for multicore architectures. In: Communicating process architectures 2007: WoTUG-30, pp 183–205
4.
Zurück zum Zitat Brown N, Welch P (2003) An introduction to the Kent C++ CSP Library. Commun Process Archit 2003:139–156 Brown N, Welch P (2003) An introduction to the Kent C++ CSP Library. Commun Process Archit 2003:139–156
5.
Zurück zum Zitat Brown NC (2004) C++ CSP networked. Commun Process Archit 2004:185–200 Brown NC (2004) C++ CSP networked. Commun Process Archit 2004:185–200
6.
Zurück zum Zitat East I, Martin J, Welch P, Duce D, Green M (2004) gCSP: a graphical tool for designing CSP systems. Commun Process Archit 2004 27:233 East I, Martin J, Welch P, Duce D, Green M (2004) gCSP: a graphical tool for designing CSP systems. Commun Process Archit 2004 27:233
7.
Zurück zum Zitat Freitas L (2002) JACK: a process algebra implementation in Java. Ph.D. thesis, Centro de Informatica, Universidade Federal de Pernambuco Freitas L (2002) JACK: a process algebra implementation in Java. Ph.D. thesis, Centro de Informatica, Universidade Federal de Pernambuco
8.
Zurück zum Zitat Gardner W (2000) CSP++: an object-oriented application framework for software synthesis from CSP specifications. Ph.D. thesis, Politecnico di Milano, Italy Gardner W (2000) CSP++: an object-oriented application framework for software synthesis from CSP specifications. Ph.D. thesis, Politecnico di Milano, Italy
9.
Zurück zum Zitat Gardner W (2003) Bridging CSP and C++ with selective formalism and executable specifications. In: Proceedings of first ACM and IEEE international conference on formal methods and models for co-design (MEMOCODE’03). IEEE, pp 237–245 Gardner W (2003) Bridging CSP and C++ with selective formalism and executable specifications. In: Proceedings of first ACM and IEEE international conference on formal methods and models for co-design (MEMOCODE’03). IEEE, pp 237–245
10.
Zurück zum Zitat Gardner W (2005) CSP++: how faithful to CSPm. In: Proc. communicating process architectures 2005 (WoTUG-27), pp 129–146 Gardner W (2005) CSP++: how faithful to CSPm. In: Proc. communicating process architectures 2005 (WoTUG-27), pp 129–146
11.
Zurück zum Zitat Hilderink G, Bakkers A, Broenink J (2000) A distributed real-time Java system based on CSP. In: Proceedings of third IEEE international symposium on object-oriented real-time distributed computing (ISORC’00). IEEE, pp 400–407 Hilderink G, Bakkers A, Broenink J (2000) A distributed real-time Java system based on CSP. In: Proceedings of third IEEE international symposium on object-oriented real-time distributed computing (ISORC’00). IEEE, pp 400–407
12.
Zurück zum Zitat Hoare C (1974) Monitors: an operating system structuring concept. Commun ACM 17(10):549–557CrossRefMATH Hoare C (1974) Monitors: an operating system structuring concept. Commun ACM 17(10):549–557CrossRefMATH
13.
Zurück zum Zitat Hoare C (1985) Communicating sequential processes. In: Prentice-Hall international series in computer science. Prentice/Hall International, London Hoare C (1985) Communicating sequential processes. In: Prentice-Hall international series in computer science. Prentice/Hall International, London
15.
Zurück zum Zitat Jones G (1986) Programming in Occam. Prentice-Hall International, London Jones G (1986) Programming in Occam. Prentice-Hall International, London
16.
Zurück zum Zitat Kleine M (2009) Using CSP for software verification. In: Proceedings of formal methods 2009 doctoral symposium. Eindhoven University of Technology, pp 8–13 Kleine M (2009) Using CSP for software verification. In: Proceedings of formal methods 2009 doctoral symposium. Eindhoven University of Technology, pp 8–13
17.
Zurück zum Zitat Kleine M (2011) CSP as a coordination language. In: Coordination models and languages. Springer, New York, pp 65–79 Kleine M (2011) CSP as a coordination language. In: Coordination models and languages. Springer, New York, pp 65–79
19.
Zurück zum Zitat Lehmberg A, Olsen M (2006) An introduction to CSP.NET. Commun Process Archit 2006:13–30 Lehmberg A, Olsen M (2006) An introduction to CSP.NET. Commun Process Archit 2006:13–30
21.
Zurück zum Zitat Liang H, Dong JS, Sun J (2007) Evolution and runtime monitoring of software systems. In: SEKE’07: Proceedings of the 19th international conference on software engineering and knowledge engineering. Knowledge Systems Institute Graduate School, Skokie, pp 343–348 Liang H, Dong JS, Sun J (2007) Evolution and runtime monitoring of software systems. In: SEKE’07: Proceedings of the 19th international conference on software engineering and knowledge engineering. Knowledge Systems Institute Graduate School, Skokie, pp 343–348
22.
Zurück zum Zitat Liang H, Dong JS, Sun J, Duke R, Seviora RE (2006) Formal specification-based online monitoring. In: ICECCS’06: proceedings of the 11th IEEE international conference on engineering of complex computer systems. IEEE Computer Society, Washington, DC, pp 152–160. doi:10.1109/ICECCS.2006.1690364 Liang H, Dong JS, Sun J, Duke R, Seviora RE (2006) Formal specification-based online monitoring. In: ICECCS’06: proceedings of the 11th IEEE international conference on engineering of complex computer systems. IEEE Computer Society, Washington, DC, pp 152–160. doi:10.​1109/​ICECCS.​2006.​1690364
23.
Zurück zum Zitat Lin SW, Liu Y, Hsiung PA, Sun J, Dong JS (2012) Automatic generation of provably correct embedded systems. In: Formal methods and software engineering. Springer, New York, pp 214–229 Lin SW, Liu Y, Hsiung PA, Sun J, Dong JS (2012) Automatic generation of provably correct embedded systems. In: Formal methods and software engineering. Springer, New York, pp 214–229
24.
Zurück zum Zitat Liu Y, Sun J, Dong JS (2011) PAT 3: an extensible architecture for building multi-domain model checkers. In: ISSRE, pp 190–199 Liu Y, Sun J, Dong JS (2011) PAT 3: an extensible architecture for building multi-domain model checkers. In: ISSRE, pp 190–199
25.
Zurück zum Zitat Mahony B, Dong JS (1998) Blending object-Z and timed CSP: an introduction to TCOZ. In: Proceedings of the 20th international conference on software engineering (ICSE’98). IEEE Computer Society, pp 95–104 Mahony B, Dong JS (1998) Blending object-Z and timed CSP: an introduction to TCOZ. In: Proceedings of the 20th international conference on software engineering (ICSE’98). IEEE Computer Society, pp 95–104
26.
Zurück zum Zitat Schaller N, Hilderink G, Welch P (2000) Using Java for parallel computing: JCSP versus CTJ, a comparison. In: Communicating process architectures, pp 205–226 Schaller N, Hilderink G, Welch P (2000) Using Java for parallel computing: JCSP versus CTJ, a comparison. In: Communicating process architectures, pp 205–226
27.
Zurück zum Zitat Summerfield M (2012) Programming in Go: creating applications for the 21st century. Addison-Wesley Professional, Menlo Park Summerfield M (2012) Programming in Go: creating applications for the 21st century. Addison-Wesley Professional, Menlo Park
28.
Zurück zum Zitat Sun J, Dong JS, Jarzabek S, Wang H (2006) Computer-aided dispatch system family architecture and verification: an integrated formal approach. IEE Proc Softw 153(3):102–112. doi:10.1049/ip-sen:20050014 Sun J, Dong JS, Jarzabek S, Wang H (2006) Computer-aided dispatch system family architecture and verification: an integrated formal approach. IEE Proc Softw 153(3):102–112. doi:10.​1049/​ip-sen:​20050014
29.
Zurück zum Zitat Sun J, Liu Y, Dong JS, Chen C (2009) Integrating specification and programs for system modeling and verification. In: Proceedings of the third IEEE international symposium on theoretical aspects of software engineering (TASE’09), pp 127–135 Sun J, Liu Y, Dong JS, Chen C (2009) Integrating specification and programs for system modeling and verification. In: Proceedings of the third IEEE international symposium on theoretical aspects of software engineering (TASE’09), pp 127–135
30.
Zurück zum Zitat Sun J, Liu Y, Dong JS, Liu Y, Shi L (2013) Étienne André: modeling and verifying hierarchical real-time systems using stateful timed CSP. ACM Trans Softw Eng Methodol 22(1):3:1–3:29. doi:10.1145/2430536.2430537 Sun J, Liu Y, Dong JS, Liu Y, Shi L (2013) Étienne André: modeling and verifying hierarchical real-time systems using stateful timed CSP. ACM Trans Softw Eng Methodol 22(1):3:1–3:29. doi:10.​1145/​2430536.​2430537
31.
Zurück zum Zitat Sun J, Liu Y, Dong JS, Pang J (2009) PAT: towards flexible verification under fairness. In: Proceedings of the 21th international conference on computer aided verification (CAV’09). Lecture notes in computer science, vol 5643. Springer, New York, pp 709–714 Sun J, Liu Y, Dong JS, Pang J (2009) PAT: towards flexible verification under fairness. In: Proceedings of the 21th international conference on computer aided verification (CAV’09). Lecture notes in computer science, vol 5643. Springer, New York, pp 709–714
33.
Zurück zum Zitat Welch P, Brown N, Moores J, Chalmers K, Sputh B (2007) Integrating and extending JCSP. Commun Process Archit 2007(65):349–370 Welch P, Brown N, Moores J, Chalmers K, Sputh B (2007) Integrating and extending JCSP. Commun Process Archit 2007(65):349–370
34.
Zurück zum Zitat Welch P, Martin J (2000) A CSP model for Java multithreading. In: Proceedings of international symposium on software engineering for parallel and distributed systems, pp 114–122 Welch P, Martin J (2000) A CSP model for Java multithreading. In: Proceedings of international symposium on software engineering for parallel and distributed systems, pp 114–122
35.
Zurück zum Zitat Welch P, Martin J (2000) Formal analysis of concurrent java systems. Commun Process Archit 58:275–301 Welch P, Martin J (2000) Formal analysis of concurrent java systems. Commun Process Archit 58:275–301
36.
Zurück zum Zitat Yang L, Poppleton M (2007) JCSProB: implementing integrated formal specifications in concurrent Java. Commun Process Archit 65:67–88 Yang L, Poppleton M (2007) JCSProB: implementing integrated formal specifications in concurrent Java. Commun Process Archit 65:67–88
37.
Zurück zum Zitat Yang L, Poppleton M (2010) Java implementation platform for the integrated state-and event-based specification in PROB. Concurr Comput Pract Exp 22(8):1007–1022CrossRef Yang L, Poppleton M (2010) Java implementation platform for the integrated state-and event-based specification in PROB. Concurr Comput Pract Exp 22(8):1007–1022CrossRef
38.
Zurück zum Zitat Yuan L, Dong JS, Sun J, Basit HA (2006) Generic fault tolerant software architecture reasoning and customization. IEEE Trans Reliab 55(3):421–435. doi:10.1109/TR.2006.879605 Yuan L, Dong JS, Sun J, Basit HA (2006) Generic fault tolerant software architecture reasoning and customization. IEEE Trans Reliab 55(3):421–435. doi:10.​1109/​TR.​2006.​879605
39.
Zurück zum Zitat Zhang J, Liu Y, Sun J, Dong JS, Sun J (2012) Model checking software architecture design. In: 2012 IEEE 14th international symposium on high-assurance systems engineering (HASE), pp 193–200. doi:10.1109/HASE.2012.12 Zhang J, Liu Y, Sun J, Dong JS, Sun J (2012) Model checking software architecture design. In: 2012 IEEE 14th international symposium on high-assurance systems engineering (HASE), pp 193–200. doi:10.​1109/​HASE.​2012.​12
Metadaten
Titel
From verified model to executable program: the PAT approach
verfasst von
Huiquan Zhu
Jing Sun
Jin Song Dong
Shang-Wei Lin
Publikationsdatum
19.12.2015
Verlag
Springer London
Erschienen in
Innovations in Systems and Software Engineering / Ausgabe 1/2016
Print ISSN: 1614-5046
Elektronische ISSN: 1614-5054
DOI
https://doi.org/10.1007/s11334-015-0269-z