Reasoning About Monotonicity in Separation Logic


Amin Timany and Lars Birkedal: Reasoning About Monotonicity in Separation Logic. In CPP 2021, January 2021. https://doi.org/10.1145/3437992.3439931
Conference Paper
Abstract.

Reasoning about monotonicity is of key importance in concurrent separation logics. For instance, one needs to reason about monotonicity to show that the value of a concurrent counter with an increment operation only grows over time. Modern concurrent separation logices, such as VST, FCSL, and Iris, are based on resource models defined using partial commutative monoids. For any partial commutative monoid, there is a canonical ordering relation, the so-called extension order, and in a sense the logics are designed to reason about monotonicity wrt. the extension ordering.

Thus a natural question is: given an arbitrary preorder, can we construct a partial commutative monoid, where the extension order captures the given preorder.

In this paper, we answer this question in the affirmative and show that there is a canonical construction, which given any preorder produces a partial commutative monoid for which the extension order, restricted to the elements of the preorder, is exactly the given preorder. We prove that our construction is a free construction in the category-theoretic sense.

We demonstrate, using examples, that the general construction is useful. We have formalized the construction and its properties in Coq. Moreover, we have integrated it in the Iris program logic framework and used that to formalize our examples.

The bibtex source for this publication:
@inproceedings{DBLP:conf/cpp/TimanyB21,
  author    = {Amin Timany and Lars Birkedal},
  editor    = {Catalin Hritcu and Andrei Popescu},
  title     = {Reasoning about monotonicity in separation logic},
  booktitle = {{CPP} ''21: 10th {ACM} {SIGPLAN} International Conference on Certified
               Programs and Proofs, Virtual Event, Denmark, January 17-19, 2021},
  pages     = {91--104},
  publisher = {{ACM}},
  year      = {2021},
  url       = {https://doi.org/10.1145/3437992.3439931},
  doi       = {10.1145/3437992.3439931},
  timestamp = {Fri, 12 Feb 2021 14:28:33 +0100},
  biburl    = {https://dblp.org/rec/conf/cpp/TimanyB21.bib},
  bibsource = {dblp computer science bibliography, https://dblp.org}
}