Update ruby and mmtk-core repo rev #130
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is a reguler merging commit that synchronizes the MMTK's CRuby fork
with the upstream.
The upstream introduced the imemo:fields type, and is now using it for
the
generic_fields_tbl_
, i.e. it now holds instance variables forobjects other than
T_OBJECT
,T_CLASS
andT_MODULE
. When usingMMTk, we treat the key-value pair in the
generic_fields_tbl_
as astrong edge, i.e. treating the imemo:fields of an object as if it were a
child. We now update the
generic_fields_tbl_
like other weak tables.This simplified the handling of generic fields table in the MMTk
binding.
With imemo:fields added, we now have 17 imemo types including MMTk's
imemo:mmtk_strbuf and imemo:mmtk_objbuf. We increased the header bits
of the imemo type to 5 bits and changed the value of some imemo-specific
header offsets, such as
ISEQ_TRANSLATED
.The upstream changed the API for acquiring/releasing the GVL. We make
changes accordingly.
YJIT assumes there is only one thread doing GC. It panics when two GC
worker threads try to mark two iseq objects simultaneously. We made
several changes to support parallel GC for YJIT-compiled iseq objects:
Block::gc_obj_offsets
withBlock::gc_obj_addresses
which are now absolute pointers instead of offsets. By doing so, we
no longer need to borrow the
Rc<RefCell<VirtualMem>>
during GC.rb_yjit_iseq_update_references
no longer usesCodeBlock
to writecode, and no longer calls
mark_all_executable
after updating eachobject. Instead we make the whole code memory writable before
updating any objects, and make it executable after the updating
phase finishes. This should both make it friendly to parallel GC
and improve performance.