Skip to content

Modify interface implementations to use invokedynamic for upcalls #9497

Description

@headius

Interface implementations using JRuby objects currently use our CachingCallSite logic for invoking the Ruby object's methods, be that object a full Ruby object or a proc/block for lambda-like interface coercion. These upcalls back into JRuby should be made more efficient in two ways:

  • By using a ScopedValue to access the ThreadContext.
  • By using InvokeDynamic to call the actual method or block body.

This would represent the "last mile" for interface performance and allow calls through such objects to inline and optimize with the Java code that calls them.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions