skip to main content
research-article
Open access

On algebraic abstractions for concurrent separation logics

Published: 04 January 2021 Publication History

Abstract

Concurrent separation logic is distinguished by transfer of state ownership upon parallel composition and framing. The algebraic structure that underpins ownership transfer is that of partial commutative monoids (PCMs). Extant research considers ownership transfer primarily from the logical perspective while comparatively less attention is drawn to the algebraic considerations. This paper provides an algebraic formalization of ownership transfer in concurrent separation logic by means of structure-preserving partial functions (i.e., morphisms) between PCMs, and an associated notion of separating relations. Morphisms of structures are a standard concept in algebra and category theory, but haven't seen ubiquitous use in separation logic before. Separating relations. are binary relations that generalize disjointness and characterize the inputs on which morphisms preserve structure. The two abstractions facilitate verification by enabling concise ways of writing specs, by providing abstract views of threads' states that are preserved under ownership transfer, and by enabling user-level construction of new PCMs out of existing ones.

Formats available

You can view the full content in the following formats:

References

[1]
Martín Abadi and Leslie Lamport. 1991. The existence of refinement mappings. Theoretical Computer Science (TCS) 82, 2 ( 1991 ), 253-284. https://doi.org/10.1016/ 0304-3975 ( 91 ) 90224-P
[2]
Samson Abramsky and Achim Jung. 1995. Domain Theory. Oxford University Press, Inc., USA, 1-168.
[3]
Andrew W. Appel, Robert Dockins, Aquinas Hobor, Lennart Beringer, Josiah Dodds, Gordon Stewart, Sandrine Blazy, and Xavier Leroy. 2014. Program Logics for Certified Compilers. Cambridge University Press. https://doi.org/10.1017/ CBO9781107256552
[4]
Gilles Barthe, Justin Hsu, and Kevin Liao. 2020a. A probabilistic separationPlroocg. iAc.CM Program. Lang. 4, POPL ( 2020 ), 55 : 1-55 : 30. https://doi.org/10.1145/3371123
[5]
Gilles Barthe, Justin Hsu, Mingsheng Ying, Nengkun Yu, and Li Zhou. 2020b. Relational proofs for quantum prPorgorca. ms. ACM Program. Lang. 4, POPL ( 2020 ), 21 : 1-21 : 29. https://doi.org/10.1145/3371089
[6]
Kevin Batz, Benjamin Lucien Kaminski, Joost-Pieter Katoen, Christoph Matheja, and Thomas Noll. 2019. Quantitative separation logic: a logic for reasoning about probabilistic pointer progProacm. sA. CM Program. Lang. 3, POPL ( 2019 ), 34 : 1-34 : 29. https://doi.org/10.1145/3290347
[7]
Josh Berdine, Cristiano Calcagno, and Peter W. O'Hearn. 2005. Symbolic Execution with Separation LPorgoigcr. aImnming Languages and Systems, Third Asian Symposium, APLAS 2005, Tsukuba, Japan, November 2-5, 2005, Proceedings. 52-68. https://doi.org/10.1007/11575467_5
[8]
Aleš Bizjak, Daniel Gratzer, Robbert Krebbers, and Lars Birkedal. 2019. Iron: managing obligations in higher-order concurrent separation logiPcr.oc. ACM Program. Lang. 3, POPL, 65 : 1-65 : 30. https://doi.org/10.1145/3290378
[9]
Richard Bornat, Cristiano Calcagno, Peter W. O'Hearn, and Mathew J. Parkinson. 2005. Permission accounting in separation logic. InACM Symposium on Principles of Programming Languages (POPL). 259-270. https://doi.org/10.1145/ 1040305.1040327
[10]
Cristiano Calcagno, Peter W. O'Hearn, and Hongseok Yang. 2007. Local Action and Abstract Separation 2L2ongdic. In IEEE Symposium on Logic in Computer Science (LICS 2007 ), 10-12 July 2007, Wroclaw, Poland, Proceedings. IEEE Computer Society, 366-378. https://doi.org/10.1109/LICS. 2007.30
[11]
Qinxiang Cao, Santiago Cuellar, and Andrew W. Appel. 2017. Bringing Order to the Separation Logic JunPrgolger. aImnming Languages and Systems-15th Asian Symposium, APLAS 2017, Suzhou, China, November 27-29, 2017, Proceedings. 190-211. https://doi.org/10.1007/978-3-319-71237-6_10
[12]
Kenta Cho. 2015. Total and Partial Computation in Categorical Quantum FoundatioPnrso. cIenedings 12th International Workshop on Quantum Physics and Logic, QPL 2015, Oxford, UK, July 15-17, 2015 (EPTCS, Vol. 195 ). 116-135. https: //doi.org/10.4204/EPTCS.195.9
[13]
Kenta Cho, Bart Jacobs, Bas Westerbaan, and Abraham Westerbaan. 2015. An Introduction to Efectus TheoCroyR.R abs/1512.05813 ( 2015 ). arXiv1 : 512.05813 http://arxiv.org/abs/1512.05813
[14]
Pedro da Rocha Pinto, Thomas Dinsdale-Young, and Philippa Gardner. 2014. TaDA: A logic for time and data abstraction. In European Conference on Object-Oriented Programming (ECOOP). 207-231. https://doi.org/10.1007/978-3-662-44202-9_9
[15]
Germán Andrés Delbianco, Ilya Sergey, Aleksandar Nanevski, and Anindya Banerjee. 2017. Concurrent data structures linked in time. InEuropean Conference on Object-Oriented Programming (ECOOP). 8 : 1-8 : 30. https://doi.org/10.4230/ LIPIcs.ECOOP. 2017.8
[16]
hTomas Dinsdale-Young, Lars Birkedal, Philippa Gardner, Mathew J. Parkinson, and Hongseok Yang. 2013. Views: compositional reasoning for concurrent programs. AICnM Symposium on Principles of Programming Languages (POPL). 287-300. https://doi.org/10.1145/2429069.2429104
[17]
hTomas Dinsdale-Young, Mike Dodds, Philippa Gardner, Mathew J. Parkinson, and Viktor Vafeiadis. 2010. Concurrent abstract predicates. IEnuropean Conference on Object-Oriented Programming (ECOOP). 504-528. https://doi.org/10. 1007/978-3-642-14107-2_24
[18]
František Farka, Aleksandar Nanevski, Anindya Banerjee, Germán Andrés Delbianco, and Ignacio Fábregas. 2020a. On Algebraic Abstractions for Concurrent Separation Logics (artefact). (October h20t2t0p)s.://doi.org/10.5281/zenodo. 4069513
[19]
František Farka, Aleksandar Nanevski, Anindya Banerjee, Germán Andrés Delbianco, and Ignacio Fábregas. 2020b. On Algebraic Abstractions for Concurrent Separation Logics (extended verCsiooRnR). (October 2020 ). https://arxiv.org/ abs/ 2010.12686
[20]
Alexey Gotsman, Josh Berdine, Byron Cook, Noam Rinetzky, and Mooly Sagiv. 2007. Local Reasoning for Storable Locks and hTreads. In Programming Languages and Systems, 5th Asian Symposium, APLAS 2007, Singapore, November 29-December 1, 2007, Proceedings (Lecture Notes in Computer Science, Vol. 4807 ), Zhong Shao (Ed.). Springer, 19-37.https://doi.org/10. 1007/978-3-540-76637-7_3
[21]
Robert Harper. 2011. The Holy Trinity. htps://existentialtype.wordpress.com/ 2011 /03/27/the-holy-trinity/.
[22]
Maurice Herlihy and Nir Shavit. 2008The. art of multiprocessor programming. M. Kaufmann. https://doi.org/10.1108/ 03684920810907904
[23]
Maurice Herlihy and Jeannete M. Wing. 1990. Linearizability: a correctness condition for concurrent oAbjCeMctsT. ransactions on Programming Languages and Systems (TOPLAS) 12, 3 ( 1990 ), 463-492. https://doi.org/10.1145/78969.78972
[24]
Jonas Kastberg Hinrichsen, Jesper Bengtson, and Robbert Krebbers. 2020. Actris: session-type based reasoning in separation logic. Proc. ACM Program. Lang. 4, POPL ( 2020 ), 6 : 1-6 : 30. https://doi.org/10.1145/3371074
[25]
Aquinas Hobor, Robert Dockins, and Andrew W. Appel. 2010. A theory of indirection via approximatiPorno. cIenedings of the 37th ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages, POPL 2010, Madrid, Spain, January 17-23, 2010. 171-184. https://doi.org/10.1145/1706299.1706322
[26]
Bart Jacobs. 2018. From probability monads to commutative efectuseJ. s.Log. Algebr. Meth. Program. 94 ( 2018 ), 200-237. https://doi.org/10.1016/j.jlamp. 2016. 11.006
[27]
Jonas Braband Jensen and Lars Birkedal. 2012. Fictional Separation LogEiScO.IPn.
[28]
Clif B. Jones. 1983. Tentative Steps Toward a Development Method for Interfering PrograAmCsM. Transactions on Programming Languages and Systems (TOPLAS) 5, 4 ( 1983 ). https://doi.org/10.1145/69575.69577
[29]
Ralf Jung, Robbert Krebbers, Jacques-Henri Jourdan, Aleš Bizjak, Lars Birkedal, and Derek Dreyer. 2018. Iris from the ground up: A modular foundation for higher-order concurrent separation lJooguircn. al of Functional Programming (JFP) 28 ( 2018 ), e20. https://doi.org/10.1017/S0956796818000151
[30]
Ralf Jung, Rodolphe Lepigre, Gaurav Parthasarathy, Marianna Rapoport, Amin Timany, Derek Dreyer, and Bart Jacobs. 2020. The future is ours: prophecy variables in separation logicP.roc. ACM Program. Lang. 4, POPL ( 2020 ), 45 : 1-45 : 32. https://doi.org/10.1145/3371113
[31]
Ralf Jung, David Swasey, Filip Sieczkowski, Kasper Svendsen, Aaron Turon, Lars Birkedal, and Derek Dreyer. 2015. Iris: monoids and invariants as an orthogonal basis for concurrent reasonAinCgM. ISnymposium on Principles of Programming Languages (POPL). 637-650. https://doi.org/10.1145/2676726.2676980
[32]
Robbert Krebbers. 2015. The C standard formalized in Coq. Phd Thesis. Radboud University Nijmegen. https://hdl.handle. net/ 2066 /147182
[33]
Neelakantan R. Krishnaswami, Aaron Turon, Derek Dreyer, and Deepak Garg. 2012. Superficially substructural types. In ICFP.
[34]
Leslie Lamport. 1974. A New Solution of Dijkstra's Concurrent Programming ProbCloem.mun. ACM 17, 8 ( 1974 ), 453-455. https://doi.org/10.1145/361082.361093
[35]
Ruy Ley-Wild and Aleksandar Nanevski. 2013. Subjective auxiliary state for coarse-grained concurreAnCcyM. ISnymposium on Principles of Programming Languages (POPL). 561-574. https://doi.org/10.1145/2429069.2429134
[36]
John M. Mellor-Crummey and Michael L. Scot. 1991. Algorithms for Scalable Synchronization on Shared-memory Multiprocessors. ACM Transactions on Computer Systems (TOCS) 9, 1 ( 1991 ), 21-65. https://doi.org/10.1145/103727.103729
[37]
Aleksandar Nanevski, Anindya Banerjee, Germán Andrés Delbianco, and Ignacio Fábregas. 2019. Specifying concurrent programs in separation logic: morphisms and simulationPAs. CMPL 3, OOPSLA ( 2019 ), 161 : 1-161 : 30. https://doi.org/ 10.1145/3360587
[38]
Aleksandar Nanevski, Ruy Ley-Wild, Ilya Sergey, and Germán Andrés Delbianco. 2014. Communicating state transition systems for fine-grained concurrent resources. InEuropean Symposium on Programming (ESOP). 290-310. https://doi. org/10.1007/978-3-642-54833-8_16
[39]
Aleksandar Nanevski, Greg Morriset, and Lars Birkedal. 2006. Polymorphism and separation in Hoare Type Theory. In Proceedings of the 11th ACM SIGPLAN International Conference on Functional Programming (ICFP 2006 ). https://doi.org/ 10.1145/1159803.1159812
[40]
David J. Pym, Peter W. O'Hearn, and Hongseok Yang. 2004. Possible worlds and resources: the semantics oTheforB. I. Comput. Sci. 315, 1 ( 2004 ), 257-305. https://doi.org/10.1016/j.tcs. 2003. 11.020
[41]
Tetsuya Sato, Alejandro Aguirre, Gilles Barthe, Marco Gaboardi, Deepak Garg, and Justin Hsu. 2019. Formal verification of higher-order probabilistic programs: reasoning about approximation, convergence, Bayesian inference, and optimization. Proc. ACM Program. Lang. 3, POPL ( 2019 ), 38 : 1-38 : 30. https://doi.org/10.1145/3290351
[42]
Ilya Sergey, Aleksandar Nanevski, and Anindya Banerjee. 2015a. Mechanized Verification of Fine-grained Concurrent Programs. In ACM Conference on Programming Languages Design and Implementation (PLDI). https://doi.org/10.1145/ 2737924.2737964
[43]
Ilya Sergey, Aleksandar Nanevski, and Anindya Banerjee. 2015b. Specifying and verifying concurrent algorithms with histories and subjectivity. EInuropean Symposium on Programming (ESOP). 333-358. https://doi.org/10.1007/978-3-662-46669-8_14
[44]
Ilya Sergey, Aleksandar Nanevski, Anindya Banerjee, and Germán Andrés Delbianco. 2016. Hoare-style specifications as correctness conditions for non-linearizable concurrent objeActCsM. InConference on Object-Oriented Programming Systems, Languages, and Applications (OOPSLA). 92-110. https://doi.org/10.1145/3022671.2983999
[45]
Kasper Svendsen and Lars Birkedal. 2014. Impredicative concurrent abstract predicatEeus. roInpean Symposium on Programming (ESOP). 149-168. https://doi.org/10.1007/978-3-642-54833-8_9
[46]
Kasper Svendsen, Lars Birkedal, and Mathew J. Parkinson. 2013. Modular reasoning about separation of concurrent data structures. InEuropean Symposium on Programming (ESOP). 169-188. https://doi.org/10.1007/978-3-642-37036-6_11
[47]
Nikhil Swamy, Aseem Rastogi, Aymeric Fromherz, Denis Merigoux, Danel Ahman, and Guido Martínez. 2020. SteelCore: an extensible concurrent separation logic for efectful dependently typed progPrraomc. sA.CM Program. Lang. 4, ICFP ( 2020 ), 121 : 1-121 : 30. https://doi.org/10.1145/3409003
[48]
Joseph Tassaroti and Robert Harper. 2019. A separation logic for concurrent randomized prograPmros.c. ACM Program. Lang. 3, POPL ( 2019 ), 64 : 1-64 : 30. https://doi.org/10.1145/3290377
[49]
Aaron Turon, Viktor Vafeiadis, and Derek Dreyer. 2014. GPS: navigating weak memory with ghosts, protocols, and separation. InProceedings of the 2014 ACM International Conference on Object Oriented Programming Systems Languagesc & Applications, OOPSLA 2014, Andrew P. Black and Todd D. Millstein (Eds.). ACM, 691-707h. ttps://doi.org/10.1145/ 2660193.2660243
[50]
Dominique Unruh. 2019a. Quantum Hoare Logic with Ghost Variables. In34th Annual ACM /IEEE Symposium on Logic in Computer Science, LICS 2019, Vancouver, BC, Canada, June 24-27, 2019. IEEE, 1-13. https://doi.org/10.1109/LICS. 2019. 8785779
[51]
Dominique Unruh. 2019b. Quantum relational Hoare logic. Proc. ACM Program. Lang. 3, POPL ( 2019 ), 33 : 1-33 : 31. https: //doi.org/10.1145/3290346

Cited By

View all
  • (2025)Verifying Graph Algorithms in Separation Logic: A Case for an Algebraic ApproachProceedings of the ACM on Programming Languages10.1145/37475109:ICFP(160-189)Online publication date: 5-Aug-2025
  • (2023)Higher-Order Leak and Deadlock Free LocksProceedings of the ACM on Programming Languages10.1145/35712297:POPL(1027-1057)Online publication date: 11-Jan-2023
  • (2023)Verification of component-based systems with recursive architecturesTheoretical Computer Science10.1016/j.tcs.2022.10.022940:PB(146-175)Online publication date: 9-Jan-2023
  • Show More Cited By

Recommendations

Comments