Asynchronous Programming, Analysis and Testing with State Machines

  • ,
  • Pantazis Deligiannis ,
  • Alastair Donaldson ,
  • Paul Thomson ,
  • Jeroen Ketema

Programming Language Design and Implementation (PLDI) |

Published by ACM

Programming efficient asynchronous systems is challenging because it can often be hard to express the design declaratively, or to defend against interleaving-dependent bugs such as data races and other assertion violations. Previous work has only addressed these challenges individually, either by designing a new declarative language, or a new data race detection tool, or a new testing technique. We present P#, a language for high-reliability asynchronous programming co-designed with a static analysis and testing infrastructure. We describe our experience using P# to write several distributed protocols and port an industrial-scale system internal to Microsoft, showing that the supporting techniques, by leveraging the design of P#, are effective in finding bugs.