Searching for deadlocks while debugging concurrent haskell programs

This paper presents an approach to searching for deadlocks in Concurrent Haskell programs. The search is based on a redefinition of the IO monad which allows the reversal of Concurrent Haskells concurrency primitives. Hence, it is possible to implement this search by a backtracking algorithm checking all possible schedules of the system. It is integrated in the Concurrent Haskell Debugger (CHD), and automatically searches for deadlocks in the background while debugging. The tool is easy to use and the small modifications of the source program are done by a preprocessor. In the tool we use iterative deepening as search strategy which quickly detects deadlocks close to the actual system configuration and utilizes idle time during debugging at the best.

[1]  Konstantin Läufer Type Classes with Existential Types , 1996, J. Funct. Program..

[2]  James C. Corbett,et al.  Bandera: extracting finite-state models from Java source code , 2000, ICSE.

[3]  Koushik Sen,et al.  An instrumentation technique for online analysis of multithreaded programs , 2004, 18th International Parallel and Distributed Processing Symposium, 2004. Proceedings..

[4]  Klaus Havelund,et al.  Using Runtime Analysis to Guide Model Checking of Java Programs , 2013, SPIN.

[5]  Colin Runciman,et al.  Complete and Partial Redex Trails of Functional Computations , 1997, Implementation of Functional Languages.

[6]  Grigore Rosu,et al.  Java PathExplorer: A Runtime Verification Tool , 2001 .

[7]  Klaus Havelund,et al.  SPIN Model Checking and Software Verification , 2000, Lecture Notes in Computer Science.

[8]  Henrik Nilsson,et al.  The Evaluation Dependence Tree as a Basis for Lazy Functional Debugging , 1997, Automated Software Engineering.

[9]  Andy Gill Debugging Haskell by Observing Intermediate Data Structures , 2000, Electron. Notes Theor. Comput. Sci..

[10]  Klaus Havelund,et al.  Model checking JAVA programs using JAVA PathFinder , 2000, International Journal on Software Tools for Technology Transfer.

[11]  Colin Runciman,et al.  Freja, Hat and Hood - A Comparative Evaluation of Three Systems for Tracing and Debugging Lazy Functional Programs , 2000, IFL.

[12]  Volker Stolz,et al.  Runtime Verification of Concurrent Haskell Programs , 2005, RV@ETAPS.

[13]  Ralf Hinze,et al.  Deriving backtracking monad transformers , 2000, ICFP '00.

[14]  Koen Claessen,et al.  A poor man's concurrency monad , 1999, Journal of Functional Programming.

[15]  Simon L. Peyton Jones,et al.  Concurrent Haskell , 1996, POPL '96.

[16]  Gill Andy Debugging Haskell by Observing Intermediate Data Structures , 2001 .

[17]  Gerard J. Holzmann Tutorial: Proving Properties of Concurrent System with SPIN , 1995, CONCUR.

[18]  Koushik Sen,et al.  Runtime safety analysis of multithreaded programs , 2003, ESEC/FSE-11.

[19]  Edmund M. Clarke,et al.  State space reduction using partial order techniques , 1999, International Journal on Software Tools for Technology Transfer.