[ruby-core:95576] [Ruby master Feature#16282] Add "call data" wrapper IMEMO object so inline cache can be updated

From: tenderlove@...
Date: 2019-10-28 23:26:16 UTC
List: ruby-core #95576
Issue #16282 has been reported by tenderlovemaking (Aaron Patterson).

----------------------------------------
Feature #16282: Add "call data" wrapper IMEMO object so inline cache can be updated
https://bugs.ruby-lang.org/issues/16282

* Author: tenderlovemaking (Aaron Patterson)
* Status: Open
* Priority: Normal
* Assignee: 
* Target version: 
----------------------------------------
Hi,

Currently the compactor will invalidate all inline caches.  I would like to update references in inline caches so we don't have to invalidate.  Most inline caches are reachable from instruction sequences, but one cache is not:

  https://github.com/ruby/ruby/blob/6147fa82a923e7318f493857023006801ed25eb5/internal.h#L2395

This static variable can't be reached from the GC.  I'd like to introduce a new IMEMO object that wraps this cache, then the GC can reach the cache and update the value.

I've attached a patch that implements the new IMEMO object, and also removes the restriction on GCC so that all compilers get the cache hit.

Does this seem OK shyouhei, ko1?

---Files--------------------------------
0001-Wrap-call-data-with-an-IMEMO-object.patch (3.8 KB)


-- 
https://bugs.ruby-lang.org/

Unsubscribe: <mailto:[email protected]?subject=unsubscribe>
<http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>

In This Thread

Prev Next