Abstract
The paper proposes a new testing technique for concurrent programs. The technique is a specification-based testing. For a formal specification <italic xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">S</i> and a concurrent program <italic xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">P</i> , state sequences are generated from <italic xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">P</i> and checked to be accepted by <italic xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">S</i> . We suppose that <italic xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">S</i> is specified in Maude and <italic xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">P</i> is implemented in Java. Java Pathfinder (JPF) and Maude are then used to generate state sequences from <italic xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">P</i> and to check if such state sequences are accepted by <italic xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">S</i> , respectively. Even without checking any property violations with JPF, JPF often encounters the notorious state space explosion while only generating state sequences. Thus, we propose a technique to generate state sequences from <italic xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">P</i> and check if such state sequences are accepted by <italic xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">S</i> in a stratified way. A tool is developed to support the proposed technique that can be processed naturally in parallel. Some experiments demonstrate that the proposed technique mitigates the state space explosion, which cannot be achieved with the straightforward use of JPF.
Highlights
Studies on testing concurrent programs [1] have been conducted for nearly 40 years or even more
For a formal specification S and a program P, to test P based on S, we can basically take each of the following two approaches: (1) P is tested with test cases generated from S and (2) it is checked that state sequences generated from P can be accepted by S
The experiments reported in the paper demonstrate that the proposed technique can mitigate the state space explosion problem and largely improve the timing performance for testing for all cases except for one, which cannot be achieved with the straightforward use of only one Java Pathfinder (JPF) instance
Summary
Studies on testing concurrent programs [1] have been conducted for nearly 40 years or even more. For a formal specification S and a (concurrent) program P , to test P based on S, we can basically take each of the following two approaches: (1) P is tested with test cases generated from S and (2) it is checked that state sequences generated from P can be accepted by S. A divide & conquer approach to testing concurrent programs that can mitigate the state space explosion problem and be naturally parallelized to improve the running performance of model checking. The rest of the paper is organized as follows: § II Preliminaries, § III Specification-based Concurrent Program Testing with a Simulation Relation, § IV State Sequence Generation from Concurrent Programs, § V A Divide & Conquer Approach to Generating State Sequences, § VI A Divide &.
Talk to us
Join us for a 30 min session where you can share your feedback and ask us any queries you have
Disclaimer: All third-party content on this website/platform is and will remain the property of their respective owners and is provided on "as is" basis without any warranties, express or implied. Use of third-party content does not indicate any affiliation, sponsorship with or endorsement by them. Any references to third-party content is to identify the corresponding services and shall be considered fair use under The CopyrightLaw.