Created
May 29, 2019 18:48
-
-
Save hotsphink/1388820d97225ed777268616379a983e to your computer and use it in GitHub Desktop.
mkgist-created gist
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
enqueueMark(obj|string) | |
Add an object to the queue of objects to mark at the beginning every GC. (Note | |
that the objects will actually be marked at the beginning of every slice, but | |
after the first slice they will already be marked so nothing will happen.) | |
Instead of an object, a few magic strings may be used: | |
'yield' - cause the current marking slice to end, as if the mark budget were | |
exceeded. | |
'enter-weak-marking-mode' - divide the list into two segments. The items after | |
this string will not be marked until we enter weak marking mode. Note that weak | |
marking mode may be entered zero or multiple times for one GC. | |
'abort-weak-marking-mode' - same as above, but then abort weak marking to fall back | |
on the old iterative marking code path. | |
'drain' - fully drain the mark stack before continuing. | |
'set-color-black' - force everything following in the mark queue to be marked black. | |
'set-color-gray' - continue with the regular GC until gray marking is possible, then force | |
everything following in the mark queue to be marked gray. | |
'unset-color' - stop forcing the mark color. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment