Skip to main content
QUICK REVIEW

[Paper Review] PrideMM: A Solver for Relaxed Memory Models

Simon Cooksey, Sarah Harris|arXiv (Cornell University)|Dec 8, 2018
Formal Methods in VerificationComputer Science49 references3 citations
TL;DR

PrideMM is a novel solver for relaxed memory models that uses second-order (SO) logic to simulate both traditional axiomatic models and newer event structure-based models, such as the Jeffrey and Riely model. It leverages a dedicated SO solver built on QBF solvers, achieving superior performance—scaling to 25-thread store-buffering tests in under a minute—outperforming existing tools like Herd and Memalloy.

ABSTRACT

Relaxed memory models are notoriously delicate. To ease their study, several ad hoc simulators have been developed for axiomatic memory models. We show how axiomatic memory models can be simulated using a solver for $\exists$SO. Further, we show how memory models based on event structures can be simulated using a solver for MSO. Finally, we present a solver for SO, built on top of QBF solvers.

Motivation & Objective

  • To address the limitations of existing simulators in handling modern, aggressively optimized concurrent languages with complex memory models.
  • To enable formal simulation of event structure-based memory models that cannot be efficiently modeled using SAT or ad hoc algorithms.
  • To demonstrate that second-order logic provides a practical balance between expressiveness and solvability for weak memory models.
  • To develop a scalable, high-performance solver for SO logic that outperforms existing tools on complex litmus tests and large-scale models.

Proposed method

  • Formalizing axiomatic memory models using existential second-order logic (∃SO), enabling direct encoding of program order, read-from, and acyclicity constraints.
  • Encoding event structure-based models (e.g., Jeffrey and Riely model) in full second-order logic (SO), capturing real dependencies and conflict relations.
  • Building a dedicated SO solver on top of QBF solvers, with optimizations like lazy quantifier expansion and hash-consing to avoid redundant subformula computation.
  • Supporting non-prenex input in the SO solver (QFM), improving efficiency over prenex-form-only solvers like QFUN.
  • Translating memory model verification tasks into SO formulas and solving them via state-of-the-art QBF solvers, with performance evaluation on standard litmus tests.
  • Validating the approach on three test sets: store-buffering problems (SC), the J+R model (Java causality), and standard axiomatic tests, using both QFM and QFUN backends.

Experimental results

Research questions

  • RQ1Can second-order logic express both axiomatic and event structure-based relaxed memory models with sufficient precision for formal simulation?
  • RQ2Can a dedicated SO solver built on QBF solvers outperform existing ad hoc or SAT-based simulators like Herd and Memalloy in scalability and performance?
  • RQ3Does the use of advanced solver techniques—such as lazy quantifier expansion and hash-consing—significantly improve performance on complex memory model instances?
  • RQ4Can the SO-based approach handle models like the Jeffrey and Riely model, which are incompatible with traditional SAT-based or ad hoc simulation methods?
  • RQ5How does the performance of a custom SO solver (QFM) compare to off-the-shelf QBF solvers (QFUN) on memory model verification tasks?

Key findings

  • PrideMM successfully simulates the 25-thread store-buffering problem (100 events) in under one minute, a task that exceeds the scalability of Herd7.
  • The QFM backend of PrideMM solved all 15 instances of the J+R model within 6 minutes per instance, while QFUN solved all but two, demonstrating the advantage of a purpose-built SO solver.
  • The QFM solver outperformed QFUN despite using the same core algorithm, due to optimized quantifier expansion via hash-consing and support for non-prenex input.
  • CAQE, a CNF-based QBF solver, was inadequate for the SO-based problems, highlighting the need for native SO support in such solvers.
  • All satisfiability results matched expected outcomes from prior work, confirming correctness of the encoding and solver stack.
  • The approach enables simulation of a new class of memory models (e.g., J+R, P+S, Kang et al.) that are not expressible in the limited language of SAT or ad hoc algorithms.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.