• Michael Lippautz's avatar
    [api, global-handles] Add TracedGlobal · 76c93685
    Michael Lippautz authored
    TracedGlobal integrates with the use case of EmbedderHeapTracer and replaces
    regular weak Global or Persistent nodes for such cases. This allows to simplify
    the case for regular weak handles in a sense that they follow regular weak
    semantics (if the underlying object is otherwise unreachable the weak handle
    will be reset).
    
    TracedGlobal requires slightly different semantics in the sense that it can be
    required to keep them alive on Scavenge garbage collections because there's a
    transitive path that is only known when using the EmbedderHeapTracer.
    TracedGlobal accomodates that use case.
    
    TracedGlobal follows move semantics and can thus be used in regular std
    containers without wrapping data structure.
    
    The internal state uses 20% less memory and allows for only iterating those
    nodes when necessary. The design trades the virtual call when iterating
    interesting persistents in the GC prologue with calling out through the
    EmbedderHeapTracer for each node which is also a virtual call. There is one less
    iteration over the set of handles required though and the design is robust
    against recursive GCs that mutate the embedder state during the prologue
    callback.
    
    Bug: chromium:923361
    Change-Id: Idbacfbe4723cd12af9de21058a4792e51dc4df74
    Reviewed-on: https://chromium-review.googlesource.com/c/1425523
    Commit-Queue: Michael Lippautz <mlippautz@chromium.org>
    Reviewed-by: 's avatarUlan Degenbaev <ulan@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#59183}
    76c93685
Name
Last commit
Last update
..
benchmarks Loading commit data...
cctest Loading commit data...
common Loading commit data...
debugger Loading commit data...
fuzzer Loading commit data...
inspector Loading commit data...
intl Loading commit data...
js-perf-test Loading commit data...
memory Loading commit data...
message Loading commit data...
mjsunit Loading commit data...
mkgrokdump Loading commit data...
mozilla Loading commit data...
preparser Loading commit data...
test262 Loading commit data...
torque Loading commit data...
unittests Loading commit data...
wasm-js Loading commit data...
wasm-spec-tests Loading commit data...
webkit Loading commit data...
BUILD.gn Loading commit data...