Rely-Guarantee Protocols

  • Filipe Militão
  • Jonathan Aldrich
  • Luís Caires
Conference paper

DOI: 10.1007/978-3-662-44202-9_14

Volume 8586 of the book series Lecture Notes in Computer Science (LNCS)
Cite this paper as:
Militão F., Aldrich J., Caires L. (2014) Rely-Guarantee Protocols. In: Jones R. (eds) ECOOP 2014 – Object-Oriented Programming. ECOOP 2014. Lecture Notes in Computer Science, vol 8586. Springer, Berlin, Heidelberg

Abstract

The use of shared mutable state, commonly seen in object-oriented systems, is often problematic due to the potential conflicting interactions between aliases to the same state. We present a substructural type system outfitted with a novel lightweight interference control mechanism, rely-guarantee protocols, that enables controlled aliasing of shared resources. By assigning each alias separate roles, encoded in a novel protocol abstraction in the spirit of rely-guarantee reasoning, our type system ensures that challenging uses of shared state will never interfere in an unsafe fashion. In particular, rely-guarantee protocols ensure that each alias will never observe an unexpected value, or type, when inspecting shared memory regardless of how the changes to that shared state (originating from potentially unknown program contexts) are interleaved at run-time.

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

Copyright information

© Springer-Verlag Berlin Heidelberg 2014

Authors and Affiliations

  • Filipe Militão
    • 1
    • 2
  • Jonathan Aldrich
    • 1
  • Luís Caires
    • 2
  1. 1.Carnegie Mellon UniversityPittsburghUSA
  2. 2.Universidade Nova de LisboaLisboaPortugal