Skip to content
This repository

[invokedynamic] Instance var sites do not age, do not handle dup'ed classes well #155

headius opened this Issue · 0 comments

1 participant

Charles Oliver Nutter
Charles Oliver Nutter
headius commented

Instance variable call sites currently attempt to cache in a way similar to method calls. However, they do not ever age out (i.e. give up trying to update the indy call site) and as a result sites that encounter a large number of types will either grow the PIC forever or continually blow out the call site cache.

This needs to be fixed for JRuby 1.7, so that megamorphic ivar call sites failover to a simple inline cache.

An example of invokedynamic.log.binding output showing the continual rebinding of ivars is here:

Charles Oliver Nutter headius closed this issue from a commit
Charles Oliver Nutter Fix #155
If an instance variable encounters too many types it will give up
trying to bind directly and fail over to a simple inline cache as
in the non-invokedynamic compiler. This should prevent churn of
polymorphic ivar call sites.
Charles Oliver Nutter headius closed this in b0c4eaa
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.