Efficient Dispatch of Java Interface Methods

  • Authors:
  • Bowen Alpern;Anthony Cocchi;David Grove;Derek Lieber

  • Affiliations:
  • -;-;-;-

  • Venue:
  • HPCN Europe 2001 Proceedings of the 9th International Conference on High-Performance Computing and Networking
  • Year:
  • 2001

Quantified Score

Hi-index 0.00

Visualization

Abstract

Virtual methods can be dispatched efficiently because the code for corresponding methods reside at the same entries in their respective virtual method tables (VMTs). To achieve efficient interface method dispatch, a fixed-sized interface method table (IMT) is associated with each class. Different implementations of the same interface method signature reside at the same entry in their respective IMTs. When a class implements two or more interface methods with the same IMT offset, a conflict resolution stub distinguishes between them at runtime. The resulting interface method dispatch is almost as cheap as its virtual counterpart.