Verifying Lock-free Search Structure Templates
Nisarg Patel, Dennis Shasha, Thomas Wies
TL;DR
This work develops template algorithms for lock-free concurrent search structures (lists and skiplists) and provides modular, mechanized proofs of linearizability using Iris. It parameterizes skiplists by height $L$, traversal style (eager vs lazy), node implementations, and higher-level maintenance order, enabling a single verification to cover many variants. A central technical advance is the formalization of hindsight reasoning within Iris, along with a general framework for relating hindsight-based specifications to client-level atomic specifications via prophecy variables and a helping protocol. The authors demonstrate substantial proof-effort reductions (e.g., a 53% reduction in a multicopy template) and verify unbounded-height skiplists, contributing a scalable approach to the formal verification of complex lock-free data structures with practical impact for correctness guarantees in concurrent systems.
Abstract
We present and verify template algorithms for lock-free concurrent search structures that cover a broad range of existing implementations based on lists and skiplists. Our linearizability proofs are fully mechanized in the concurrent separation logic Iris. The proofs are modular and cover the broader design space of the underlying algorithms by parameterizing the verification over aspects such as the low-level representation of nodes and the style of data structure maintenance. As a further technical contribution, we present a mechanization of a recently proposed method for reasoning about future-dependent linearization points using hindsight arguments. The mechanization builds on Iris' support for prophecy reasoning and user-defined ghost resources. We demonstrate that the method can help to reduce the proof effort compared to direct prophecy-based proofs.
