skip to main content
research-article
Free Access

A Theory of Synchronous Relational Interfaces

Published:01 July 2011Publication History
Skip Abstract Section

Abstract

Compositional theories are crucial when designing large and complex systems from smaller components. In this work we propose such a theory for synchronous concurrent systems. Our approach follows so-called interface theories, which use game-theoretic interpretations of composition and refinement. These are appropriate for systems with distinct inputs and outputs, and explicit conditions on inputs that must be enforced during composition. Our interfaces model systems that execute in an infinite sequence of synchronous rounds. At each round, a contract must be satisfied. The contract is simply a relation specifying the set of valid input/output pairs. Interfaces can be composed by parallel, serial or feedback composition. A refinement relation between interfaces is defined, and shown to have two main properties: (1) it is preserved by composition, and (2) it is equivalent to substitutability, namely, the ability to replace an interface by another one in any context. Shared refinement and abstraction operators, corresponding to greatest lower and least upper bounds with respect to refinement, are also defined. Input-complete interfaces, that impose no restrictions on inputs, and deterministic interfaces, that produce a unique output for any legal input, are discussed as special cases, and an interesting duality between the two classes is exposed. A number of illustrative examples are provided, as well as algorithms to compute compositions, check refinement, and so on, for finite-state interfaces.

Skip Supplemental Material Section

Supplemental Material

References

  1. Abadi, M. and Lamport, L. 1995. Conjoining specifications. ACM Trans. Program. Lang. Syst. 17, 3, 507--535. Google ScholarGoogle ScholarDigital LibraryDigital Library
  2. Abrial, J.-R. 1996. The B-book: Assigning Programs to Meanings. Cambridge University Press, New York, NY. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. Alur, R. and Henzinger, T. 1999. Reactive modules. Form. Meth. Syst. Des. 15, 7--48. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. Alur, R., Henzinger, T., Kupferman, O., and Vardi, M. 1998. Alternating refinement relations. In Proceedings of the International Conference on Concurrency Theory (CONCUR’98). Lecture Notes in Computer Science, vol. 1466. Springer. Google ScholarGoogle ScholarDigital LibraryDigital Library
  5. Back, R.-J. and Wright, J. 1998. Refinement Calculus. Springer.Google ScholarGoogle Scholar
  6. Barringer, H., Kuiper, R., and Pnueli, A. 1984. Now you may compose temporal logic specifications. In Proceedings of the 16th ACM Symposium on Theory of Computing (STOC’84). ACM, New York, NY, 51--63. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. Benveniste, A., Caspi, P., Edwards, S., Halbwachs, N., Le Guernic, P., and de Simone, R. 2003. The synchronous languages 12 years later. Proc. IEEE 91, 1, 64--83.Google ScholarGoogle Scholar
  8. Benveniste, A., Caillaud, B., Ferrari, A., Mangeruca, L., Passerone, R., and Sofronis, C. 2008. Multiple viewpoint contract-based specification and design. In Proceedings of the 6th International Symposium on Formal Methods for Components and Objects (FMCO’07). Springer, 200--225. Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. Berry, G. 1999. The constructive semantics of Pure Esterel. http://www-sop.inria.fr/esterel.org/.Google ScholarGoogle Scholar
  10. Broy, M. 1997. Compositional refinement of interactive systems. J. ACM 44, 6, 850--891. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. Broy, M. and Stølen, K. 2001. Specification and Development of Interactive Systems: Focus on Streams, Interfaces, and Refinement. Springer. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. Caspi, P., Pilaud, D., Halbwachs, N., and Plaice, J. 1987. Lustre: A declarative language for programming synchronous systems. In Proceedings of the 14th ACM Symposium on Principles of Programming Languages (POPL’87). ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. Chakrabarti, A., de Alfaro, L., Henzinger, T., and Mang, F. 2002. Synchronous and bidirectional component interfaces. In Proceedings of the International Conference on Computer Aided Verification. Lecture Notes in Computer Science vol. 2404, Springer, 414--427. Google ScholarGoogle ScholarDigital LibraryDigital Library
  14. Cheon, Y. and Leavens, G. 1994. The Larch/Smalltalk interface specification language. ACM Trans. Softw. Eng. Methodol. 3, 3, 221--153. Google ScholarGoogle ScholarDigital LibraryDigital Library
  15. de Alfaro, L. 2004. Game models for open systems. In Verification: Theory and Practice, N. Dershowitz Ed., Lecture Notes in Computer Science Series, vol. 2772, Springer, 192--213.Google ScholarGoogle Scholar
  16. de Alfaro, L. and Henzinger, T. 2001a. Interface automata. In Foundations of Software Engineering (FSE). ACM Press. Google ScholarGoogle ScholarDigital LibraryDigital Library
  17. de Alfaro, L. and Henzinger, T. 2001b. Interface theories for component-based design. In Proceedings of the International Workshop on Embedded Software (EMSOFT’01). Lecture Notes in Computer Science, vol. 2211, Springer. Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. Desharnais, J. and Möller, B. 2005. Least reflexive points of relations. Higher Order Symbol. Comput. 18, 1--2, 51--77. Google ScholarGoogle ScholarDigital LibraryDigital Library
  19. Dhara, K. and Leavens, G. 1996. Forcing behavioral subtyping through specification inheritance. In Proceedings of the 18th International Conference on Software Engineering (ICSE’96). IEEE Computer Society, 258--267. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. Dijkstra, E. 1972. Notes on structured programming. In Structured Programming, O. Dahl, E. Dijkstra, and C. Hoare Eds., Academic Press, London, UK, 1--82. Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. Dill, D. 1987. Trace Theory for Automatic Hierarchical Verification of Speed-Independent Circuits. MIT Press, Cambridge, MA. Google ScholarGoogle ScholarDigital LibraryDigital Library
  22. Doyen, L., Henzinger, T., Jobstmann, B., and Petrov, T. 2008. Interface theories with component reuse. In Proceedings of the 8th ACM & IEEE International Conference on Embedded Software. 79--88. Google ScholarGoogle ScholarDigital LibraryDigital Library
  23. Floyd, R. 1967. Assigning meanings to programs. In Proceedings of the Symposium on Applied Mathematics. American Mathematical Society, 19--32.Google ScholarGoogle ScholarCross RefCross Ref
  24. Frappier, M., Mili, A., and Desharnais, J. 1998. Unifying program construction and modification. Logic J. IGPL 6, 317--340.Google ScholarGoogle ScholarCross RefCross Ref
  25. Grumberg, O. and Long, D. 1994. Model checking and modular verification. ACM Trans. Program. Lang. Syst. 16, 3, 843--871. Google ScholarGoogle ScholarDigital LibraryDigital Library
  26. Guttag, J. and Horning, J. 1993. Larch: Languages and Tools for Formal Specification. Springer. Google ScholarGoogle ScholarDigital LibraryDigital Library
  27. Hehner, E. and Parnas, D. 1985. Technical correspondence. Comm. ACM 28, 5, 534--538. Google ScholarGoogle ScholarDigital LibraryDigital Library
  28. Henzinger, T. and Sifakis, J. 2007. The discipline of embedded systems design. IEEE Computer 40, 10, 32--40. Google ScholarGoogle ScholarDigital LibraryDigital Library
  29. Henzinger, T., Qadeer, S., and Rajamani, S. 1998. You assume, we guarantee: Methodology and case studies. In Proceedings of the International Conference on Computer-Aided Verification. Lecture Notes in Computer Science, vol. 1427, Springer-Verlag. Google ScholarGoogle ScholarDigital LibraryDigital Library
  30. Hoare, C. A. R. 1969. An axiomatic basis for computer programming. Comm. ACM 12, 10, 576--580. Google ScholarGoogle ScholarDigital LibraryDigital Library
  31. Hoare, C. A. R. 1985. Programs are predicates. In Proceedings of a Discussion Meeting of the Royal Society of London on Mathematical Logic and Programming Languages. Prentice-Hall, Inc., Upper Saddle River, NJ, 141--155. Google ScholarGoogle ScholarDigital LibraryDigital Library
  32. Jones, C. B. 1983. Tentative steps toward a development method for interfering programs. ACM Trans. Program. Lang. Syst. 5, 4. Google ScholarGoogle ScholarDigital LibraryDigital Library
  33. Jonsson, B. 1994. Compositional specification and verification of distributed systems. ACM Trans. Program. Lang. Syst. 16, 2, 259--303. Google ScholarGoogle ScholarDigital LibraryDigital Library
  34. Kahl, W. 2003. Refinement and development of programs from relational specifications. Electron. Notes Theor. Comput. Sci. 44, 3, 51--93.Google ScholarGoogle ScholarCross RefCross Ref
  35. Leavens, G. 1994. Inheritance of interface specifications. SIGPLAN Notes 29, 8, 129--138. Google ScholarGoogle ScholarDigital LibraryDigital Library
  36. Leavens, G. and Cheon, Y. 2006. Design by contract with JML. http://www.jmlspecs.org/jmldbc.pdf.Google ScholarGoogle Scholar
  37. Lee, E. 2008. Cyber physical systems: Design challenges. Tech. rep. UCBIEECS-2008-8, EECS Department, University of California, Berkeley.Google ScholarGoogle Scholar
  38. Lee, E. and Sangiovanni-Vincentelli, A. 1998. A unified framework for comparing models of computation. IEEE Trans. Comput.-Aid. Des. Integr. Circ. Syst. 17, 12, 1217--1229. Google ScholarGoogle ScholarDigital LibraryDigital Library
  39. Lee, E. and Xiong, Y. 2001. System-level types for component-based design. In Proceedings of the International Workshop on Embedded Software (EMSOFT’01). Springer, 237--253. Google ScholarGoogle ScholarDigital LibraryDigital Library
  40. Liskov, B. 1979. Modular program construction using abstractions. In Abstract Software Specifications. Lecture Notes in Computer Science Series, vol. 86., Springer, 354--389. Google ScholarGoogle ScholarDigital LibraryDigital Library
  41. Liskov, B. and Wing, J. 1994. A behavioral notion of subtyping. ACM Trans. Program. Lang. Syst. 16, 6, 1811--1841. Google ScholarGoogle ScholarDigital LibraryDigital Library
  42. Lublinerman, R. and Tripakis, S. 2008. Modularity vs. Reusability: Code Generation from Synchronous Block Diagrams. In Proceedings of the Conference and Exhibition on Design, Automation, and Test in Europe (DATE’08). ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  43. Lynch, N. and Tuttle, M. 1989. An introduction to input/output automata. CWI Quart. 2, 219--246.Google ScholarGoogle Scholar
  44. Malik, S. 1994. Analysis of cyclic combinational circuits. IEEE Trans. Comput.-Aid. Des. 13, 7, 950--956.Google ScholarGoogle ScholarDigital LibraryDigital Library
  45. McMillan, K. 1997. A compositional rule for hardware design refinement. In Proceedings of the International Conference on Computer Aided Verification (CAV’97). Lecture Notes in Computer Science, vol. 1254, Springer-Verlag. Google ScholarGoogle ScholarDigital LibraryDigital Library
  46. Meyer, B. 1992. Applying “design by contract.” Comput. 25, 10, 40--51. Google ScholarGoogle ScholarDigital LibraryDigital Library
  47. Miller, S., Whalen, M., and Cofer, D. 2010. Software model checking takes off. Comm. ACM 53, 2, 58--64. Google ScholarGoogle ScholarDigital LibraryDigital Library
  48. Misra, J. and Chandy, K. 1981. Proofs of networks of processes. IEEE Trans. Softw. Engin. 7, 4, 417--426. Google ScholarGoogle ScholarDigital LibraryDigital Library
  49. Nelson, G. 1989. A generalization of Dijkstra’s calculus. ACM Trans. Program. Lang. Syst. 11, 4, 517--561. Google ScholarGoogle ScholarDigital LibraryDigital Library
  50. Nierstrasz, O. 1993. Regular types for active objects. SIGPLAN Notes 28, 10, 1--15. Google ScholarGoogle ScholarDigital LibraryDigital Library
  51. Parnas, D. 1983. A generalized control structure and its formal definition. Comm. ACM 26, 8, 572--581. Google ScholarGoogle ScholarDigital LibraryDigital Library
  52. Pierce, B. 2002. Types and Programming Languages. MIT Press. Google ScholarGoogle ScholarDigital LibraryDigital Library
  53. Raclet, J.-B., Badouel, E., Benveniste, A., Caillaud, B., Legay, A., and Passerone, R. 2010. A modal interface theory for component-based design. http://www.irisa.fr/distribcom/benveniste/pub/Fundamenta2010.htm1.Google ScholarGoogle Scholar
  54. Ravindran, K. and Yang, G. 2010. Personal communication.Google ScholarGoogle Scholar
  55. Roy, P. and Shankar, N. 2010. An expressive type system for Simulink. In Proceedings of the 2nd NASA Formal Methods Symposium (NFM’10). 149--160.Google ScholarGoogle Scholar
  56. Shankar, N. 1998. Lazy compositional verification. In Compositionality: The Significant Difference. Springer, 541--564. Google ScholarGoogle ScholarDigital LibraryDigital Library
  57. Spivey, J. M. 1989. The Z Notation: A Reference Manual. Prentice-Hall, Inc., Upper Saddle River, NJ. Google ScholarGoogle ScholarDigital LibraryDigital Library
  58. Stark, E. 1985. A proof technique for rely/guarantee properties. In Proceedings of the 5th Conference on Foundations of Software Technology and Theoretical Computer Science. Springer-Verlag. Google ScholarGoogle ScholarDigital LibraryDigital Library
  59. Tourlakis, G. 2008. Mathematical Logic. Wiley. Google ScholarGoogle ScholarDigital LibraryDigital Library
  60. Tripakis, S., Lickly, B., Henzinger, T., and Lee, E. 2009a. On relational interfaces. Tech. rep. UCBIEECS-2009-60, EECS Department, University of California, Berkeley.Google ScholarGoogle Scholar
  61. Tripakis, S., Lickly, B., Henzinger, T., and Lee, E. 2009b. On relational interfaces. In Proceedings of the 7th ACM International Conference on Embedded Software (EMSOFT’09). ACM, 67--76. Google ScholarGoogle ScholarDigital LibraryDigital Library
  62. Wirth, N. 1971. Program development by stepwise refinement. Comm. ACM 14, 4, 221--227. Google ScholarGoogle ScholarDigital LibraryDigital Library
  63. Zhou, Y. and Lee, E. 2008. Causality interfaces for actor networks. ACM Trans. Embed. Comput. Syst. 7, 3, 1--35. Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. A Theory of Synchronous Relational Interfaces

        Recommendations

        Comments

        Login options

        Check if you have access through your login credentials or your institution to get full access on this article.

        Sign in

        Full Access

        • Published in

          cover image ACM Transactions on Programming Languages and Systems
          ACM Transactions on Programming Languages and Systems  Volume 33, Issue 4
          July 2011
          170 pages
          ISSN:0164-0925
          EISSN:1558-4593
          DOI:10.1145/1985342
          Issue’s Table of Contents

          Copyright © 2011 ACM

          Publisher

          Association for Computing Machinery

          New York, NY, United States

          Publication History

          • Published: 1 July 2011
          • Accepted: 1 March 2011
          • Revised: 1 November 2010
          • Received: 1 May 2010
          Published in toplas Volume 33, Issue 4

          Permissions

          Request permissions about this article.

          Request Permissions

          Check for updates

          Qualifiers

          • research-article
          • Research
          • Refereed

        PDF Format

        View or Download as a PDF file.

        PDF

        eReader

        View online with eReader.

        eReader
        About Cookies On This Site

        We use cookies to ensure that we give you the best experience on our website.

        Learn more

        Got it!