Compositional Semantics for Shared-Variable Concurrency
Mikhail Svyatlovskiy, Shai Mermelstein, Ori Lahav
Abstract
We revisit the fundamental problem of defining a compositional semantics for a concurrent programming language under sequentially consistent memory with the aim of equating the denotations of pieces of code if and only if these pieces induce the same behavior under all program contexts. While the denotational semantics presented by Brookes [Information and Computation 127, 2 (1996)] has been considered a definitive solution, we observe that Brookes’s full abstraction result crucially relies on the availability of an impractical whole-memory atomic read-modify-write instruction. In contrast, we consider a language with standard primitives, which apply to a single variable. For that language, we propose an alternative denotational semantics based on traces that track program write actions together with the writes expected from the environment, and equipped with several closure operators to achieve necessary abstraction. We establish the adequacy of the semantics, and demonstrate full abstraction for the case that the analyzed code segment is loop-free. Furthermore, we show that by including a whole-memory atomic read in the language, one obtains full abstraction for programs with loops. To gain confidence, our results are fully mechanized in Coq.
Ask about this paper
Your agent reads all of it.
Lune indexed this paper to the last equation, along with the top-tier papers that cite it. Ask a question and the answer quotes them.
Your agent calls
Luneget_paper_fulltext
Free to start. No credit card required.
Terminal
Install the CLIlune papers fulltext a73d666a-037f-4194-b888-ff317246bca7Builds on5
- Conditional Contextual RefinementYoungju Song, Minki Cho, Dongjae Lee, Chung-Kil Hur et al.POPL 2023 · 29 citations
- Pomsets with preconditions: a simple model of relaxed memoryRadha Jagadeesan, Alan Jeffrey, James RielyOOPSLA 2020 · 28 citations
- The leaky semicolon: compositional semantic dependencies for relaxed-memory concurrencyAlan Jeffrey, James Riely, Mark Batty, Simon Cooksey et al.POPL 2022 · 21 citations
- An Operational Approach to Library Abstraction under Relaxed Memory ConcurrencyAbhishek Kr Singh, Ori LahavPOPL 2023 · 11 citations
- Sequential reasoning for optimizing compilers under weak memory concurrencyMinki Cho, Sung-Hwan Lee, Dongjae Lee, Chung-Kil Hur et al.PLDI 2022 · 11 citations
Related papers
- Modular data-race-freedom guarantees in the promising semanticsMinki Cho, Sung-Hwan Lee, Chung-Kil Hur, Ori LahavPLDI 2021 · 14 citations
- Verifying observational robustness against a c11-style memory modelRoy David Margalit, Ori LahavPOPL 2021 · 22 citations
- Decidable verification under a causally consistent shared memoryOri Lahav, Udi BokerPLDI 2020 · 30 citations
- Putting Weak Memory in Order via a Promising Intermediate RepresentationSung-Hwan Lee, Minki Cho, Roy David Margalit, Chung-Kil Hur et al.PLDI 2023 · 5 citations
- Rely-Guarantee Reasoning for Causally Consistent Shared MemoryOri Lahav, Brijesh Dongol, Heike WehrheimCAV 2023 · 11 citations
