skip to main content
10.1145/248156.248163acmconferencesArticle/Chapter ViewAbstractPublication PagescommConference Proceedingsconference-collections
Article
Free Access

Generating efficient protocol code from an abstract specification

Authors Info & Claims
Published:28 August 1996Publication History

ABSTRACT

A protocol compiler takes as input an abstract specification of a protocol and generates an implementation of that protocol. Protocol compilers usually produce inefficient code both in terms of code speed and code size. In this paper, we show that the combination of two techniques makes it possible to build protocol compilers that generate efficient code. These techniques are i) the use of a compiler that generates from the specification a unique tree-shaped automaton (rather than multiple independent automata), and ii) the use of optimization techniques applied at the automaton level, i.e. on the branches of the trees.We have developed a protocol compiler that uses both these techniques. The compiler takes as input a protocol specification written in the synchronous language Esterel. The specification is compiled into a unique automaton by the Esterel front end compiler. The automaton is then optimized and converted into C code by our protocol optimizer called HIPPCO. HIPPCO improves code performance and reduces code size by simultaneously optimizing the performance of the common path and optimizing the size of the uncommon path. We evaluate the gain expected with our approach on a real-life example, namely a working subset of the TCP protocol generated from an Esterel specification. We compare the protocol code generated with our approach to that derived from the standard BSD TCP implementation. The results are very encouraging. HIPPCO-generated code executes up to 25 % fewer instructions than the BSD code for input packet processing while maintaining comparable code size.

References

  1. 1.G. Berry and G. Gonthier. The Esterel synchronous programming language: Design, semantic, implementation. Technical Report 842, INRIA, Sophia-Antipolis, France, 1988.]]Google ScholarGoogle Scholar
  2. 2.G~rard Berry. Real-time programming: Special purpose or general purpose languages. In Information Processing IFIP Conference, Elsevier Science Publishers, B.V. North Holland, September 1989.]]Google ScholarGoogle Scholar
  3. 3.G~rard Berry and Georges Gonthier. Incremental development of an HDLC protocol in esterel. Technical Report 1031, INRIA, Sophia-Antipolis, France, May 1989.]]Google ScholarGoogle Scholar
  4. 4.Frederic Boussinot and Robert de Simone. The ESTEREL language. Technical Report 1487, INRIA, Sophia-Antipolis, France, July 1991.]]Google ScholarGoogle ScholarCross RefCross Ref
  5. 5.L. Brakmo and L. Peterson. Performance problems in bsd4.4 tcp. Computer Communication Review, (5):69-86, October 1995.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. 6.C. Castelluccia, I. Chrisment, W. Dabbous, C. Diot, C. Huitema, E. Siegel, and R. De Simone. Tailored protocol development using esterel. Technical Report 2374, INRIA, Sophia-Antipolis, France, Octobre 1994.]]Google ScholarGoogle Scholar
  7. 7.Claude Castelluccia. Automating header prediction. In Proceedings of the 1st Annual Workshop on Compiler Support For System Software, Tucson, Arizona, February 1996.]]Google ScholarGoogle Scholar
  8. 8.Claude Castelluccia and Walid Dabbous. Modular communication subsystem implementation using a synchronous approach. In Proceedings of the Usenix High-Speed Networking Symposium, pages 1-11, Oakland, California, August 1994.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. 9.Claude Castelluccia and Walid Dabbous. HIPPCO: an High performance protocol code optimizer. Technical Report 2748, INRIA, Sophia-Antipolis, France, December 1995.]]Google ScholarGoogle Scholar
  10. 10.Claude Castelluccia and Phillip Hoschka. A compiler-based approach to protocol optimization. In S.-P. Chang, editor, Proceeding of the High Performance Communication Subsystem Workshop, Mistic, Connecticut, USA, August 1995.]]Google ScholarGoogle Scholar
  11. 11.P. Chang, S. Mahlke, and W. Hwu. Using profile information to assist classic code optimizations. Software-Practice and Experience, 21(12):1301-1321, 1991.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. 12.D. Clark, V. Jacobson, J. Romkey, and M. Salwen. An analysis of TCP processing overhead. IEEE Communications Magazine, 27(6):23-29, June 1989.]]Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. 13.David D. Clark and David L. Tennenhouse. Architectural considerations for a new generation of protocols. In Proceedings of the A CM Symposium on Communications Architectures and Protocols, pages 200-208, Philadelphia, Pennsylvania, September 1990. IEEE. Computer Communications Review, Vol. 20(4), Sept. 1990.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  14. 14.K. D. Cooper, M. W. Hall, and L. Torczon. An experiment with inline substitution. Software-Practice and Experience, pages 581-601, June 1991.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  15. 15.Jon Crowcroft, Ian Wakeman, Zheng Wang, and Dejan Sirovica. Layering considered harmful. IEEE Network Magazine, January 1991.]]Google ScholarGoogle Scholar
  16. 16.Jack W. Davidson and Anne M. Holler. Subprogram inlining: A study of a c function inliner. Software-Practice and Experience, 18:775-790, 1988.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  17. 17.David C. Feldmeier. A survey of high performance protocol implementation techniques. Technical report, Bellcore, February 1993.]]Google ScholarGoogle Scholar
  18. 18.Per Gunningberg, Craig Partridge, Teet Sirotkin, and Bjorn Victor. Delayed evaluation of gigabit protocols. In Proceedings of the Second MultiC Workshop, Stockholm, Sweden, June 1991.]]Google ScholarGoogle Scholar
  19. 19.J. L. Hennesy and D. D. Patterson. Computer Architecture: A Quantitative Approach. Morgan Kaufmann, San Mateo, California, 1990.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. 20.B. Hoffmann and W. Effelsberg. Efficient implementation of Estelle specification. Technical Report 3/93, Universitat Mannheim, Mannheim, Germany, March 1993.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. 21.Philipp Hoschka. Optimisation Automatique dans un Compilateur de Talon de Communication. PhD thesis, INRIA, Sophia Antipolis, France, July 1995.]]Google ScholarGoogle Scholar
  22. 22.Norman C. Hutchinson and Larry L. Peterson. Design of the x-kernel. In Proceedings of the A CM Symposium on Communications Architectures and Protocols, pages 65-75, Stanford, California, August 1988. ACM. also in Computer Communication Review 18 (4), Aug. 1988.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  23. 23.S. Leue and Ph. Oechslin. Optimization techniques for parallel protocol implementation. In Proceedings of the Fourth IEEE Workshop on Future Trends in Distributed Computing Systems, pages 387-393, 1992.]]Google ScholarGoogle Scholar
  24. 24.J.A. Manas and T. de Miguel. From LOTOS to C. In Proceedings of the International Conference on Formal Description Techniques for Distributed Systems and Communications Protocols, pages 79-84, 1988.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  25. 25.Scott McFarling. Program optimization for instruction caches. In Proceedings of the Third International Conference on Architectural Support for Programming Languages and Operating Systems, pages 183-191, April 1989.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  26. 26.A. B. Montz, D. Mosberger, S. W. O'Malley, L. L. Paterson, T. A. Proebsting, and J. H. Hartman. Scout: A communications-oriented operating system. Technical Report 94-20, Computer Sciences Department - University of Arizona, Tucson, Arizona, USA, June 1994.]]Google ScholarGoogle Scholar
  27. 27.David Mosberger, Larry L. Peterson, and Sean O'Malley. Protocol latency: MIPS and reality. Technical Report TR 95-02, Department of Computer Science, University of Arizona, Tucson, Arizona, January 1995.]]Google ScholarGoogle Scholar
  28. 28.Philippe Oechslin. Implementation Optimis~e de Protocoles a Haut D~bits. PhD thesis, EPFL Lausanne, Lausanne, Switzerland, 1995.]]Google ScholarGoogle Scholar
  29. 29.K. Pettis and R. C. Hansen. Profile guided code positioning. In Proceedings of the A CM $IGPLAN'90 Conference on Programming Language Design and Implementation, pages 16-27, June 1990.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  30. 30.V. Roy and R. de Simone. Auto and autograph. In Proceedings of the Workshop on Computer Aided Verification, June 1990.]]Google ScholarGoogle Scholar
  31. 31.K. Trivedi. Probability and Statistics with Reliability, Queuing and Computer Science. Englewood Cliffs: Prentice Hall, 1982.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  32. 32.Son T. Vuong, Allen C. Lau, and R. Isaac Chan. Semiautomatic implementation of protocols using an Estelle-C compiler. IEEE Transactions on Software Engineering, 14(3):384-393, March 1988.]] Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. Generating efficient protocol code from an abstract specification

        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
        • Published in

          cover image ACM Conferences
          SIGCOMM '96: Conference proceedings on Applications, technologies, architectures, and protocols for computer communications
          August 1996
          330 pages
          ISBN:0897917901
          DOI:10.1145/248156

          Copyright © 1996 ACM

          Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

          Publisher

          Association for Computing Machinery

          New York, NY, United States

          Publication History

          • Published: 28 August 1996

          Permissions

          Request permissions about this article.

          Request Permissions

          Check for updates

          Qualifiers

          • Article

          Acceptance Rates

          SIGCOMM '96 Paper Acceptance Rate27of162submissions,17%Overall Acceptance Rate554of3,547submissions,16%

        PDF Format

        View or Download as a PDF file.

        PDF

        eReader

        View online with eReader.

        eReader