Font Size: a A A

MonitorExplorer: A state-space exploration based tool to test Java monitors implementations

Posted on:2007-07-16Degree:M.SType:Thesis
University:The University of Texas at ArlingtonCandidate:Gupta, VidurFull Text:PDF
GTID:2448390005969646Subject:Computer Science
Abstract/Summary:
A monitor is a concurrency construct that encapsulates data and functionality for allocating and releasing shared resources [1]. Java associates a lock with every object. When a block of code is guarded by the 'synchronized' keyword then the thread has to get lock on objects inside the block. This block is a Java Monitor which guarantees mutual exclusion and the thread needs to get the locks before it can enter the monitor. The locks are released when the thread exits the guarded block. If the thread is not able to get all the locks it waits for the conditions to be right.;There are many application classes which are written using the Java Monitors and these are difficult to test due to the inherent complexities of the concurrent programs. The key challenge is to be able to trace all possible execution paths and then able to reproduce them for regression testing. Our work explores the state-space of the monitor application. The state space is explored in the depth first fashion. At each state the possible transitions are calculated pushed on a stack. The transition on the top of the stack is executed. This process is repeated till a duplicate or invalid state is detected.;The key features of the approach are data abstraction which helps reduce the number of states to be explored and introduction of threads on the fly to execute the selected transition that simulate the race conditions. We have developed 'MonitorExplorer', a tool that can used to test monitor applications. This tool has been used to test various applications and their mutants. The experimental results show that the tool is effective in detecting synchronization bugs.
Keywords/Search Tags:Monitor, Tool, Test, Java, State
Related items