• Mike Stanton's avatar
    [TurboFan] Serializing context information · 386ff6e5
    Mike Stanton authored
    In TurboFan, context specialization is an optimization that tries to
    either replace the load of a value from the context with a constant,
    or if that can't be achieved, at least reduce the hops up the
    context chain by starting a walk to the required depth from the
    first constant context that it can reach.
    
    Currently, this optimization is performed by looking into the
    heap during a reducer pass. With fully concurrent TurboFan, we
    need to instead gather information about contexts we may want
    to perform this optimization on during serialization.
    
    This CL adds functionality to the serializer to recognize and
    model operations that affect the context register. We add to the
    hinting structure already used by the serializer. There is
    a new type of hint: a VirtualContext. This is a tuple consisting
    of a handle to a Context, and a distance field that indicates how
    far away in a to-be-realized chain this VirtualContext sits from
    the context in the handle. For example:
    
    bytecode stream:
    ...
    CreateBlockContext
    ...
    
    After a block context is created, the accumulator now contains
    a VirtualContext Hint with a distance of 1 from any context hints
    that we are keeping track of in the current context register.
    
    More details in the design doc here:
    https://docs.google.com/document/d/1Y0LKKCEenLWyAZTetoAIpKTZRCxaNdkYV8X1GaCax2A/edit?usp=sharing
    
    Change-Id: I63732ebd106cc138fb1e9789d0676ece63e15d27
    Bug: v8:7790
    Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1605941
    Commit-Queue: Michael Stanton <mvstanton@chromium.org>
    Reviewed-by: 's avatarGeorg Neis <neis@chromium.org>
    Reviewed-by: 's avatarMaya Lekova <mslekova@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#62370}
    386ff6e5
Name
Last commit
Last update
..
api Loading commit data...
asmjs Loading commit data...
ast Loading commit data...
base Loading commit data...
builtins Loading commit data...
codegen Loading commit data...
common Loading commit data...
compiler Loading commit data...
compiler-dispatcher Loading commit data...
d8 Loading commit data...
date Loading commit data...
debug Loading commit data...
deoptimizer Loading commit data...
diagnostics Loading commit data...
execution Loading commit data...
extensions Loading commit data...
flags Loading commit data...
handles Loading commit data...
heap Loading commit data...
ic Loading commit data...
init Loading commit data...
inspector Loading commit data...
interpreter Loading commit data...
json Loading commit data...
libplatform Loading commit data...
libsampler Loading commit data...
logging Loading commit data...
numbers Loading commit data...
objects Loading commit data...
parsing Loading commit data...
profiler Loading commit data...
protobuf Loading commit data...
regexp Loading commit data...
roots Loading commit data...
runtime Loading commit data...
sanitizer Loading commit data...
snapshot Loading commit data...
strings Loading commit data...
tasks Loading commit data...
third_party Loading commit data...
torque Loading commit data...
tracing Loading commit data...
trap-handler Loading commit data...
utils Loading commit data...
wasm Loading commit data...
zone Loading commit data...
DEPS Loading commit data...
OWNERS Loading commit data...