Skip to main content

Taming message passing: Efficient method look-up for dynamically typed languages

  • Conference paper
  • First Online:
Book cover Object-Oriented Programming (ECOOP 1994)

Part of the book series: Lecture Notes in Computer Science ((LNCS,volume 821))

Included in the following conference series:

Abstract

Method look-up for dynamically typed object-oriented languages, such as smalltalk-80 or objective-c, is usually implemented by a cached inheritance search. Unfortunately, this technique is slow. A selector-indexed dispatch table implementation speeds up messages to within 10% of the speed of a statically typed language such as C++. We present a fast technique for generating compact selector-indexed dispatch tables.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. Agessen, O., Palsberg, J., Schwartzbach, M.: Type Inference of SELF: Analysis of Objects with Dynamic and Multiple Inheritance. Proc. ECOOP'93, Seventh European Conference on Object-Oriented Programming, Springer-Verlag, 1993, pp. 247–267.

    Google Scholar 

  2. André, P., Royer, J.-C: Optimizing Method Search with Lookup Caches and Incremental Coloring. Proc. OOPSLA'92, Vancouver, BC, Canada, 1992, pp. 110–126.

    Google Scholar 

  3. Ballard, S., Shirron, S.: The Design and Implementation of VAX/Smalltalk-80. In [14].

    Google Scholar 

  4. Chambers, C., Ungar, D., Lee, E.: An Efficient Implementation of SELF, a Dynamically Typed Object Oriented Programming Language. Proc. OOPSLA'89, New Orleans, LA, 1989, pp. 211–214.

    Google Scholar 

  5. Conroy, T., Pelegri-Llopart, E.: An Assessment of Method-Lookup Caches for Smalltalk-80 Implementations. In [14].

    Google Scholar 

  6. Cox, B.: Object-Oriented Programming: An Evolutionary Approach. Addison-Wesley, Reading, MA, 1987.

    Google Scholar 

  7. Dencker, P., Dürre, K., Heuft, I: Optimization of Parser Tables for Portable Compilers. ACM TOPLAS, 6, 4 (1984) 546–572.

    Article  Google Scholar 

  8. Deutsch, L.P., Schiffman, A.: Efficient Implementation of the Smalltalk-80 System, Proc. 11th Symp.on Principles of Programming Languages, Salt Lake City, UT, 1984, pp. 297–301.

    Google Scholar 

  9. Dixon, R., McKee, T., Schweitzer, P., Vaughan, M.: A Fast Method Dispatcher for Compiled Languages with Multiple Inheritance. Proc. OOPSLA'89s, New Orleans, LA, Oct. 1989. Published as SIGPLAN Notices 24, 10, (1989) 211–214.

    Article  Google Scholar 

  10. Driesen, K.: Selector Table Indexing & Sparse Arrays.Proc. OOPSLA'93, Washington, DC, 1993, pp. 259–170.

    Google Scholar 

  11. Driesen, K.: Method Lookup Strategies in Dynamically Typed Object-Oriented Programming Languages, Masters Thesis. Vrije Universiteit Brussel, 1993.

    Google Scholar 

  12. Dussud, P.: TICLOS: An implementation of CLOS for the Explorer Family. Proc. OOPSLA'89, New Orleans, LA, 1989, pp. 215–219.

    Google Scholar 

  13. Ellis, M.A., Stroustrup, B.: The Annotated C++ Reference Manual. Addison-Wesley, Reading, MA, 1990.

    Google Scholar 

  14. Goldberg, A., Robson, D.: Smalltalk-80: The Language and its Implementation, second edition, Addison-Wesley, Reading, MA, 1985.

    Google Scholar 

  15. Hoelzle, U., Chamber, C., Ungar, D.: Optimizing Dynamically-Typed Object-Oriented Languages With Polymorphic Inline Caches. Proc. ECOOP'93, Seventh European Conf. on Object-Oriented Programming, Springer-Verlag, 1993, pp. 21–38.

    Google Scholar 

  16. Huang, S.-K., Chen, D.-J.: Efficient algorithms for method dispatch in object-oriented programming systems, Journal of Object Oriented Programming, Sept. 1992, pp. 43–54.

    Google Scholar 

  17. Kiczales, G., Rodriguez, L.: Efficient Method Dispatch in PCL. Proc. ACM Conf. on Lisp and Functional Programming, 1990, pp. 99–105.

    Google Scholar 

  18. Krasner, G.: Smalltalk-80 Bits of History, Words of Advice. Addison-Wesley, Reading, MA, 1983.

    Google Scholar 

  19. Koenig, A.: How Virtual Functions Work. Journal of Object Oriented Programming, January/February 1989, pp. 73–74.

    Google Scholar 

  20. Meyer, B.: Object-Oriented Software Construction, Prentice Hall, 1989.

    Google Scholar 

  21. NeXT, Concepts: Objective-C, Release 3.1, NeXT Computer, Inc. 1993.

    Google Scholar 

  22. Pugh, W., Weddell, G.: Two-directional record layout for multiple inheritance, Proc. of ACM SIGPLAN'90 Conf. on Programming Languages Design and Implementation, White Plains, NY, June 1990, pp. 85–91.

    Google Scholar 

  23. Rose, J.: Fast Dispatch Mechanisms for Stock Hardware. OOPSLA'88 Conference Proceedings, San Diego, CA, Nov. 1988. Published as SIGPLAN Notices 23, 11 (1988) 27–35.

    Article  Google Scholar 

  24. Thomas, D.: The Time/Space Requirements of Object-Oriented Programs, Journal of Object-Oriented Programming, March/April 1989, pp. 71–73.

    Google Scholar 

  25. Ungar, D., Patterson, D.: Berkeley Smalltalk: Who Knows Where the Time Goes? In [14].

    Google Scholar 

  26. Ungar, D., Smith, R.: SELF: The Power of Simplicity, Lisp And Symbolic Computation: An International Journal 4, 3 (1991).

    Google Scholar 

  27. Vitek, J, Horspool, R.N., Uhl, J.: Compile-time analysis of object-oriented programs, Proc. CC'92,4th Int. Conf. on Compiler Construction, Paderborn, Germany, Springer-Verlag, 1992., pp. 236–250

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Mario Tokoro Remo Pareschi

Rights and permissions

Reprints and permissions

Copyright information

© 1994 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Vitek, J., Horspool, R.N. (1994). Taming message passing: Efficient method look-up for dynamically typed languages. In: Tokoro, M., Pareschi, R. (eds) Object-Oriented Programming. ECOOP 1994. Lecture Notes in Computer Science, vol 821. Springer, Berlin, Heidelberg. https://doi.org/10.1007/BFb0052195

Download citation

  • DOI: https://doi.org/10.1007/BFb0052195

  • Published:

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-540-58202-1

  • Online ISBN: 978-3-540-48567-4

  • eBook Packages: Springer Book Archive

Publish with us

Policies and ethics