Abstract
Many advantages have been given for using formal specifications in the design and implementation of communication systems. Performance is usually not among them. It is commonly believed that code generated by an automatic tool from a formal specification is inherently slower than code implemented manually. This paper gives experimental evidence that this contention might be false. The key idea is to integrate heuristics used by a human programmer when optimizing code into the code generation tool. This way, the tool can generate code that is competitive with code written by a human programmer, and even better for specifications of sufficient complexity. Experiments were conducted using the presentation conversion routines generated by an ASN.1 compiler. The paper describes the design and implementation of an optimisation stage that automates the trade-off between code size and execution speed in these routines. For this purpose, a heuristic method to predict the frequency of type usage is developed, based on static control flow analysis of the type reference graph of an ASN.1 specification. Experimental results show that this approach can successfully identify the most frequently used types in a specification.
Chapter PDF
Similar content being viewed by others
References
Aho, A., Sethi, R., & Ullman, J. (1986). Compilers - Principles, Techniques and Tools. Reading: Addison-Wesley.
Ball, T., & Larus, J. (1993). Branch Prediction For Free. In ACM SIGPLAN ’83 Confer-ence on Programming Language Design and Implementation, (pp. 300–313 ).
Belina, F., & Hogrefe, D. (1989). The CCITT-Specification and Description Language SDL. Computer Networks and ISDN Systems, 16 (4).
Berry, G., & Gonthier, G. (1992). The Esterel Synchronous Programming Language. Journal of Science of Computer Programming, 19 (2), 87–152.
Budowski, S., & Dembinski, P. (1988). An Introduction to Estelle. Computer Networks and ISDN Systems, 14.
Castelluccia, C., & Hoschka, P. (1995). A Compiler-Based Approach to Protocol Optimization. Proceedings “Third IEEE Workshop on the Architecture and Implementation of High Performance Communication Subsystems”
Chung, S., Lazowska, E., Notkin, D., & Zahorjan, J. (1989). Performance Implications of Design Alternatives for Remote Procedure Call Stubs. In Distributed Computing Systems, (pp. 36–41 ).
Clark, D., Jacobson, V., Romkey, J., & Salwen, H. (1989). An Analysis of TCP Processing Overhead. IEEE Communications Magazine, 23–29.
Clark, D., & Tennenhouse, D. (1990). Architectural Considerations for a New Generation of Protocols. In ACM SIGCOMM ’80, (pp. 200–208 ).
Corbin, J. (1990). The Art of Distributed Applications. 1990: Springer.
Graham, S., Kessler, P., & McKusick, M. (1983). An Execution Profiler for Modular Programs. Software–Practice and Experience, 13, 671–685.
Hoschka, P., & Huitema, C. (1993). Control Flow Analysis for Automatic Fast Path Implementation. In A. Tantawy (Ed.), Second Workshop on High Performance Communication Subsystems, (pp. 29–33 ).
Hoschka, P., & Huitema, C. (1994). Automatic Generation of Optimized Code for Marshaling Routines. In Manuel Medina & N. Borenstein (Ed.), IFIP TC6/WG6. 5 International Working Conference on Upper Layer Protocols, Architectures and Applications, (pp. 131–146 ).
Huitema, C. (1991). MAVROS: Highlights on an ASN.1 Compiler (Internal Working Paper 5). INRIA-RODEO.
Huitema, C., & Doghri, A. (1989). Defining Faster Transfer Syntaxes for the OSI Presentation Protocol. ACM Computer Communication Review, 19 (5), 44–55.
Kessler, P. (1994). A Client-Side Stub Interpreter. ACM SIGPLAN Notices, 29(8), 94–100.
Knuth, D. (1971). An empirical Study of FORTRAN Programs. Software–Practice and Experience, 1, 105–133.
Martello, S., & Toth, P. (1990). Knapsack Problems. Chichester: John Wiley.
McFarling, S., & Hennessy, J. (1986). Reducing the Cost of Branches. In 13th Annual Symposium on Computer Architecture, (pp. 396–403 ).
O’Malley, S., Proebsting, T., & Montz, A. (1994). USC: A Universal Stub Compiler. In ACM SIGCOMM ’84, (pp. 295–307).
Pagan, F. (1988). Converting Interpreters into Compilers. Software–Practice and Experience, 18 (6), 509–524.
Pettis, K., & Hansen, R. (1990). Profile Guided Code Positioning. In ACM SIGPLAN ’80 Conference on Programming Language Design and Implementation, (pp. 16–27).
Pittman, T. (1987). Two-Level Hybrid Interpreter/Native Code Execution for Combined Space-Time Program Efficiency. ACM SIGPLAN Notices, 150–152.
Ramamoorthy, C. V. (1965). Discrete Markov Analysis of Computer Programs. In ACM National Conference, (pp. 386–392 ).
Sample, M. (1993). Snacc 1.1: A High Performance ASN.1 to C/C++ Compiler ( Manual University of British Columbia, Vancouver.
Steedman, D. (1990). Abstract Syntax Notation One (ASN. 1 ) The Tutorial and Reference. London: Twickenham Appraisals.
Thekkath, C., & Levy, H. (1993). Limits to Low Latency Communication on High-Speed Networks. ACM Transactions on Computer Systems, 11 (2), 179–203.
Zahn, L., Dineen, T., Leach, P., Martin, E., Mishkin, N, Pato, J., & Wyant, G. (1990). Network Computing Architecture. Englewood Cliffs: Prentice-Hall.
Author information
Authors and Affiliations
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 1996 IFIP International Federation for Information Processing
About this chapter
Cite this chapter
Hoschka, P. (1996). Automating Performance Optimisation by Heuristic Analysis of A Formal Specification. In: Gotzhein, R., Bredereke, J. (eds) Formal Description Techniques IX. IFIP Advances in Information and Communication Technology. Springer, Boston, MA. https://doi.org/10.1007/978-0-387-35079-0_5
Download citation
DOI: https://doi.org/10.1007/978-0-387-35079-0_5
Publisher Name: Springer, Boston, MA
Print ISBN: 978-1-5041-2883-4
Online ISBN: 978-0-387-35079-0
eBook Packages: Springer Book Archive