Concurrency bugs in multithreaded software: modeling and analysis using Petri nets
- First Online:
- Cite this article as:
- Liao, H., Wang, Y., Cho, H.K. et al. Discrete Event Dyn Syst (2013) 23: 157. doi:10.1007/s10626-012-0139-x
In this paper, we apply discrete-event system techniques to model and analyze the execution of concurrent software. The problem of interest is deadlock avoidance in shared-memory multithreaded programs. We employ Petri nets to systematically model multithreaded programs with lock acquisition and release operations. We define a new class of Petri nets, called Gadara nets, that arises from this modeling process. We investigate a set of important properties of Gadara nets, such as liveness, reversibility, and linear separability. We propose efficient algorithms for the verification of liveness of Gadara nets, and report experimental results on their performance. We also present modeling examples of real-world programs. The results in this paper lay the foundations for the development of effective control synthesis algorithms for Gadara nets.