2019 IEEE 16th International Conference on Networking, Sensing and Control (ICNSC) | 2019

A Petri-net-based Method For Detecting Bugs in Multiple Threads

 
 
 
 

Abstract


A multi-thread program easily suffers from concurrent bugs such as livelock, deadlock and data inconsistency. The Petri-net-based methods are widely used to detect these errors. The existing models are good at modeling the logical structures such concurrency and synchronization locks, but short of modeling the changes of variables. However, some bugs are closely related with the changes of variables. In order to solve this problem, we put forward a new Petri net model called multi-thread net. This model can characterize overwriting, shared reading and synchronization locks. Moreover, we present a method to construct a reachability graph for every multi-thread net. Based on this graph, we develop an algorithm to detect concurrent bugs including deadlock, data race, order violation, and atomic violation. Furthermore, a Petri net tool is developed to model current programs and detect their concurrent bugs.

Volume None
Pages 150-156
DOI 10.1109/ICNSC.2019.8743177
Language English
Journal 2019 IEEE 16th International Conference on Networking, Sensing and Control (ICNSC)

Full Text