Abstract
Object-oriented systems must implement message dispatch efficiently in order not to penalize the object-oriented programming style. We characterize the performance of most previously published dispatch techniques for both statically- and dynamically-typed languages with both single and multiple inheritance. Hardware organization (in particular, branch latency and superscalar instruction issue) significantly impacts dispatch performance. For example, inline caching may outperform C++-style “vtables” on deeply pipelined processors even though it executes more instructions per dispatch.
We also show that adding support for dynamic typing or multiple inheritance does not significantly impact dispatch speed for most techniques, especially on superscalar machines. Instruction space overhead (calling sequences) can exceed the space cost of data structures (dispatch tables), so that minimal table size may not imply minimal run-time space usage.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Preview
Unable to display preview. Download preview PDF.
9 References
Ole Agesen, Jens Palsberg, and Michael I. Schwartzbach. Type Inference of Self: Analysis of Objects with Dynamic and Multiple Inheritance. In ECOOP’ 93 Conference Proceedings, p. 247–267. Kaiserslautern, Germany, July 1993.
Ole Agesen and Urs Hölzle. Type Feedback vs. Concrete Type Inference: A Comparison of Optimization Techniques for Object-Oriented Languages. Technical Report TRCS 95-04, Department of Computer Science, UCSB, March 1995.
Eric Amiel, Olivier Gruber, and Eric Simon. Optimizing Multi-Method Dispatch Using Compressed Dispatch Tables. In OOPSLA’ 94 Conference Proceedings, pp. 244–258, October 1994. Published as SIGPLAN Notices 29(10), October 1994.
P. André and J.-C. Royer. Optimizing Method Search with Lookup Caches and Incremental Coloring. OOPSLA’ 92 Conference Proceedings, Vancouver, Canada, October 1992. Published as SIGPLAN Notices 27(10), October 1992.
Apple Computer, Inc. Object Pascal User’s Manual. Cupertino, 1988.
Brad Calder and Dirk Grunwald. Reducing Indirect Function Call Overhead in C++ Programs. In 21st Annual ACM Symposium on Principles of Programming Languages, p. 397–408, January 1994.
Craig Chambers, David Ungar, and Elgin Lee. An Efficient Implementation of Self, a Dynamically-Typed Object-Oriented Language Based on Prototypes. In OOPSLA’ 89 Conference Proceedings, p. 49–70, New Orleans, LA, October 1989. Published as SIGPLAN Notices 24(10), October 1989.
Craig Chambers, David Ungar, Bay-Wei Chang, and Urs Hölzle. Parents are Shared Parts: Inheritance and Encapsulation in Self. Lisp and Symbolic Computation 4(3), Kluwer Academic Publishers, June 1991.
T. Conroy and E. Pelegri-Llopart. An Assessment of Method-Lookup Caches for Smalltalk-80 Implementations. In David Robson. Smalltalk-80: The Language and its Implementation. Second Edition, Addison-Wesley, Reading, MA, 1985 [GR83].
Cypress Semiconductors. CY7C601 SPARC processor, 1990.
P. Dencker, K. Dürre, and J. Heuft. Optimization of Parser Tables for Portable Compilers. TOPLAS 6(4):546–572, 1984.
Karel Driesen, Urs Hölzle. Minimizing Row Displacement Dispatch Tables. Technical Report TRCS 95-05, Department of Computer Science, UCSB, March 1995.
O.-J. Dahl and B. Myrhaug. Simula Implementation Guide. Publication S47, Norwegian Computing Center, Oslo, March 1973.
L. Peter Deutsch and Alan Schiffman. Efficient Implementation of the Smalltalk-80 System. Proceedings of the 11th Symposium on the Principles of Programming Languages, Salt Lake City, UT, 1984.
R. Dixon, T. McKee, P. Schweitzer, and M. Vaughan. A Fast Method Dispatcher for Compiled Languages with Multiple Inheritance. OOPSLA’ 89 Conference Proceedings, pp. 211–214, New Orleans, LA, October 1989. Published as SIGPLAN Notices 24(10), October 1989.
Karel Driesen. Selector Table Indexing and Sparse Arrays. OOPSLA’ 93 Conference Proceedings, p. 259–270, Washington, D.C., 1993. Published as SIGPLAN Notices 28(10), September 1993.
Karel Driesen. Method Lookup Strategies in Dynamically-Typed Object-Oriented Programming Languages. Master’s Thesis, Vrije Universiteit Brussel, 1993.
P. Dussud. TICLOS: An implementation of CLOS for the Explorer Family. OOPSLA’ 89 Conference Proceedings, pp. 215–220, New Orleans, LA, October 1989. Published as SIGPLAN Notices 24(10), October 1989.
Margaret A. Ellis and Bjarne Stroustrup. The Annotated C++ Reference Manual. Addison-Wesley, Reading, MA, 1990.
Mary F. Fernandez. Simple and effective link-time optimization of Modula-3 programs. To appear in Proceedings of the SIGPLAN’ 95 Conference on Programming Language Design and Implementation, 1995.
Charles D. Garrett, Jeffrey Dean, David Grove, and Craig Chambers. Measurement and Application of Dynamic Receiver Class Distributions. Technical Report CSE-TR-94-03-05, University of Washington, February 1994.
Adele Goldberg and David Robson. Smalltalk-80: The Language and its Implementation. Second Edition, Addison-Wesley, Reading, MA, 1985.
Linley Gwennap. Digital leads the pack with 21164. Microprocessor Report 8(12), September 12, 1994.
John L. Hennessy and David A. Patterson. Computer Architecture: A Quantitative Approach. Morgan Kaufmann Publishers Inc. 1990.
Urs Hölzle, Craig Chambers, and David Ungar. Optimizing Dynamically-Typed Object-Oriented Languages with Polymorphic Inline Caches. In ECOOP’ 91 Conference Proceedings, Geneva, 1991. Published as Springer Verlag Lecture Notes in Computer Science 512, Springer Verlag, Berlin, 1991.
Urs Hölzle and David Ungar. Optimizing dynamically-dispatched calls with run-time type feedback. In PLDI’ 94 Conference Proceedings, pp. 326–335, Orlando, FL, June 1994. Published as SIGPLAN Notices 29(6), June 1994.
Urs Hölzle. Adaptive Optimization for Self: Reconciling High Performance with Exploratory Programming. Ph.D. Thesis, Technical Report STAN-CS-TR-94-1520, Department of Computer Science, Stanford University, 1994.
Daniel H. Ingalls. A simple technique for handling multiple polymorphism. OOPSLA’ 86 Conference Proceedings, p. 347–349, Portland, OR., 1986. Published as SIGPLAN Notices 21(11), November 1986.
Gregor Kiczales and Louis Rodriguez. Efficient Method Dispatch in PCL. Proc. ACM Conference on Lisp and Functional Programming, 1990. Also in [Pae93].
Glenn Krasner. Smalltalk-80: Bits of History, Words of Advice. Addison-Wesley, Reading, MA, 1983.
Stein Krogdahl. Multiple inheritance in Simula-like languages. BIT 25, p. 318–326, 1985.
S. Milton and Heinz W. Schmidt. Dynamic Dispatch in Object-Oriented Languages. Technical Report TR-CS-94-02, The Australian National University, Canberra, January 1994.
MIPS Inc. R4000 Technical Brief, 1992.
MIPS Inc. R10000 Technical Brief, September 1994.
Nicholas Oxhøy, Jens Palsberg, and Michael I. Schwartzbach. Making Type Inference Practical. In ECOOP’ 92 Conference Proceedings, p. 329–349, Utrecht, The Netherlands, June/July 1992
Andreas Paepcke (ed.). Object-Oriented Programming: The CLOS Perspective, MIT Press, 1993.
John Plevyak and Andrew A. Chien. Precise concrete type inference for object-oriented languages. In OOPSLA’ 94 Conference Proceedings, pp. 324–340, October 1994. Published as SIGPLAN Notices 29(10), October 1994.
William Pugh and Grant Weddell. Two-Directional Record Layout for Multiple Inheritance. In Proceedings of the SIGPLAN’ 90 Conference on Programming Language Design and Implementation, p. 85–91, White Plains, NY, June, 1990. Published as SIGPLAN Notices 25(6), June 1990.
John Rose. Fast Dispatch Mechanisms for Stock Hardware. OOPSLA’88 Conference Proceedings, p. 27–35, San Diego, CA, November 1988. Published as SIGPLAN Notices 23(11), November 1988.
David Ungar and David Patterson. Berkeley Smalltalk: Who Knows Where the Time Goes? In David Robson. Smalltalk-80: The Language and its Implementation. Second Edition, Addison-Wesley, Reading, MA, 1985 [GR83].
David Ungar. The Design and Evaluation of a High-Performance Smalltalk System. MIT Press, Cambridge, MA, 1987.
David Ungar and David Patterson. What Price Smalltalk? In IEEE Computer 20(1), January 1987.
Jan Vitek and R. N. Horspool. Taming Message Passing: Efficient Method Look-Up for Dynamically-Typed Languages. In ECOOP’ 94 Conference Proceedings, Bologna, Italy, 1994.
Jan Vitek and R.N. Horspool, Fast Constant-Time Type Inclusion Tests, Unpublished manuscript, 1995.
Jan Vitek. Compact Dispatch Tables for Dynamically-Typed Object-Oriented Languages. M.S. Thesis, University of Victoria, B.C., forthcoming.
Jan Vitek, R. N. Horspool, and J. Uhl. Compile-time analysis of object-oriented programs. Proc. CC’92, 4th International Conference on Compiler Construction, pp. 236–250, Paderborn, Germany, Springer-Verlag, 1992.
Author information
Authors and Affiliations
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 1995 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Driesen, K., Hölzle, U., Vitek, J. (1995). Message Dispatch on Pipelined Processors. In: Tokoro, M., Pareschi, R. (eds) ECOOP’95 — Object-Oriented Programming, 9th European Conference, Åarhus, Denmark, August 7–11, 1995. ECOOP 1995. Lecture Notes in Computer Science, vol 952. Springer, Berlin, Heidelberg. https://doi.org/10.1007/3-540-49538-X_13
Download citation
DOI: https://doi.org/10.1007/3-540-49538-X_13
Published:
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-540-60160-9
Online ISBN: 978-3-540-49538-3
eBook Packages: Springer Book Archive