Skip to main content
Log in

Modeling Multithreaded Applications Using Petri Nets

  • Published:
International Journal of Parallel Programming Aims and scope Submit manuscript

Abstract

Since most modern computing systems contain multiple processing elements, applications are relying on multithreaded programming techniques that allow a program to execute multiple tasks concurrently to take advantage of the processing capabilities. Multithreaded programs are more difficult to design and test because of the nondeterministic execution orders and synchronization among the threads. Different approaches can be used to test Multithreaded Applications. In our approach we use Petri nets to represent the key elements of interactions among threads to identify potential problems such as race conditions, lost signals, and deadlocks. A tool called C2Petri has been developed which converts C-Pthreads programs to the equivalent Petri net model. This tool helps verification of Pthread-based programs. At present the tool has limited capabilities and we hope to expand the capabilities of our tool in the near future.

This is a preview of subscription content, log in via an institution to check access.

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Similar content being viewed by others

REFERENCES

  1. L. Lamport, How to Make Multiprocessor Computer that Correctly Executes Multiprocess Programs, IEEE Trans. Computers, pp. 241–248 (September 1979).

  2. S. Savage, Michael Burrows, Greg Nelson, and Patrick Sobalvarro, Eraser: A Dynamic Data Race Detector for Multithreaded Programs, ACM Trans. Comp. Sys, Vol. 15, No. 4 (November 1997).

  3. SunSoft, Lock Lint User's Guide, SunSoft Manual (August 1994).

  4. M. B. Dwyer and L. A. Clarke, FLow Analysis for Verifying Specifications of Concurrent and Distributed Software, Technical Report 1999-1952, University of Massachusetts, Amherst (August 1999). ftp://ftp.cs.umass.edu/pub/techrept/techreport/ 1999/UM-CS-1999-052.ps.

    Google Scholar 

  5. B. M. Cantrill and Thomas W. Doeppner, Jr., Thread Mon, A Tool for Monitoring Multithreaded Program Performance, Department of Computer Science, Brown University Providence, Rhode Island.

  6. A. Silberschatz, P. B. Galvin, and G. Gagne, Operating System Concepts, First Edition, John Wiley (2000).

  7. T. Murata, Petri Nets: Properties, Analysis and Applications, Proc. IEEE, 77(4), 541–580 (1989).

    Google Scholar 

  8. Dec-Alpha, Pthreads Man Pages, Dec-Alpha System Users Manual.

  9. A. R. Moshtaghi, Modeling Multithreaded Programs Using Petri Nets, MS Thesis, Dept.of ECE, The University of Alabama in Huntsville, Huntsville, Alabama (May 2001).

    Google Scholar 

  10. M. Heiner, Petri Net Based Software Validation Prospects and Limitations, The International Computer Science Institute, University of California at Berkeley, TR-92-022 (March 1992).

  11. J. W. Anneck and M. Naedele, Modeling Hierarchical and Recursive Structures Using Parametric Petri Net, Proc. High Performance Computing HPC'99, San Diego, California, pp. 445–452 (1999).

  12. K. M. Kavi, B. P. Bukhles, and U. N. Bhat, Isomorphism Between Petri Net and Dataflow Graphs, IEEE Trans. Software Engineering, Vol. SE-13, No. 10 (November 1987).

  13. K. M. Kavi, F. T. Sheldon, and S. Reed, Specification and Analysis of Real-Time Systems using CSP and Petri Nets, Int'l. J. Software Engineering and Knowledge Engineering, Vol. 6, No. 2, pp. 229–248 (June 1996).

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Rights and permissions

Reprints and permissions

About this article

Cite this article

Kavi, K.M., Moshtaghi, A. & Chen, Dj. Modeling Multithreaded Applications Using Petri Nets. International Journal of Parallel Programming 30, 353–371 (2002). https://doi.org/10.1023/A:1019917329895

Download citation

  • Issue Date:

  • DOI: https://doi.org/10.1023/A:1019917329895

Navigation