Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stop devirtualizing interface calls in preexistence #6773

Merged
merged 1 commit into from
Oct 18, 2022

Commits on Mar 26, 2022

  1. Stop devirtualizing interface calls in preexistence

    Previously, it was possible for the JIT to devirtualize an interface
    call, and for execution to reach the call (whether inlined or not) with
    a receiver that is not an instance of the class expected by the
    implementing method. The callee could then access fields of the receiver
    as though it were of the expected type.
    
    The conditionals added in this commit still allow (on their own) for an
    interface call to be devirtualized when preexistence has already proven
    that the receiver is an instance of some particular class that
    implements the expected interface. However, preexistence currently fails
    to devirtualize in that situation. It passes the class to
    TR_PersistentCHTable::findSingleInterfaceImplementer(), which needs the
    interface. This can be improved in the future by having preexistence
    treat the call in the same way as a non-interface call, but with the
    added requirement that the devirtualized callee must be public.
    jdmpapin committed Mar 26, 2022
    Configuration menu
    Copy the full SHA
    f5ab765 View commit details
    Browse the repository at this point in the history