InstantCheck: Checking the Determinism of Parallel Programs Using On-the-fly Incremental Hashing

  • by Adrian Nistor, Department of Computer Science, Illinois
  • Thursday, September 30, 2010 at 4 PM (Central Time)
  • 3405 Siebel Center for Computer Science

  • Will be activated at day/time of seminar.

Abstract: Presentation is based on MICRO10 paper by Adrian Nistor, Darko Marinov, and Josep Torrellas.


Developing multithreaded programs in shared-memory systems is difficult. One key reason is the nondeterminism of thread interaction, which may result in one code input producing different outputs in different runs. Unfortunately, enforcing determinism by construction typically comes at a performance, hardware, or programmability cost. An alternative is to check during testing whether code is deterministic.

This paper presents InstantCheck, a novel technique that checks determinism with a very small runtime overhead while requiring only a minor hardware extension. During code testing, InstantCheck can check whether the code under test ends up in a deterministic state in various runs. The idea is to compute a 64-bit hash of the memory state and compare the hashes of different test runs that have the same input. If two runs have different hashes, InstantCheck reports state nondeterminism. For efficient operation, InstantCheck uses on-the-fly incremental hashing in hardware. The hash is kept in a per-core 64-bit register, which trivially supports virtualization, migration, and context switching.

We use InstantCheck to understand the determinism properties of 17 popular applications, including Sphinx3, PBZip2, PARSEC, and SPLASH-2. InstantCheck incurs a negligible average runtime overhead of 0.4% over native testing runs. We also show how using InstantCheck programmers can find bugs and discuss other applications of fast memory-state hashing. While using InstantCheck, we found a real bug in the widely used PARSEC benchmark.

Bio: Adrian Nistor is a third year graduate student. His interests include architecture support for improving the programmability of multicore systems. His recent projects ask the question: "if you had one register (and some logic) to spend, how would you improve programmability with that?" In this talk, Nistor will present our answer for determinism checking. In a previous MICRO'09 paper, we answered this question for data races.

This presentation is OPEN to the public.