• mlippautz's avatar
    [heap] Parallel newspace evacuation, semispace copy, and compaction \o/ · 8f0fd8c0
    mlippautz authored
    All parallelism can be turned off using --predictable, or --noparallel-compaction.
    
    This patch completely parallelizes
     - semispace copy: from space -> to space (within newspace)
     - newspace evacuation: newspace -> oldspace
     - oldspace compaction: oldspace -> oldspace
    
    Previously newspace has been handled sequentially (semispace copy, newspace
    evacuation) before compacting oldspace in parallel. However, on a high level
    there are no dependencies between those two actions, hence we parallelize them
    altogether. We base the number of evacuation tasks on the overall set of
    to-be-processed pages (newspace + oldspace compaction pages).
    
    Some low-level details:
     - The hard cap on number of tasks has been lifted
     - We cache store buffer entries locally before merging them back into the global
       StoreBuffer in a finalization phase.
     - We cache AllocationSite operations locally before merging them back into the
       global pretenuring storage in a finalization phase.
     - AllocationSite might be compacted while they would be needed for newspace
       evacuation. To mitigate any problems we defer checking allocation sites for
       newspace till merging locally buffered data.
    
    CQ_EXTRA_TRYBOTS=tryserver.v8:v8_linux_arm64_gc_stress_dbg,v8_linux_gc_stress_dbg,v8_mac_gc_stress_dbg,v8_linux64_asan_rel,v8_linux64_tsan_rel,v8_mac64_asan_rel
    BUG=chromium:524425
    LOG=N
    R=hpayer@chromium.org, ulan@chromium.org
    
    Review URL: https://codereview.chromium.org/1577853007
    
    Cr-Commit-Position: refs/heads/master@{#33523}
    8f0fd8c0
Name
Last commit
Last update
..
OWNERS Loading commit data...
array-buffer-tracker.cc Loading commit data...
array-buffer-tracker.h Loading commit data...
gc-idle-time-handler.cc Loading commit data...
gc-idle-time-handler.h Loading commit data...
gc-tracer.cc Loading commit data...
gc-tracer.h Loading commit data...
heap-inl.h Loading commit data...
heap.cc Loading commit data...
heap.h Loading commit data...
incremental-marking-inl.h Loading commit data...
incremental-marking-job.cc Loading commit data...
incremental-marking-job.h Loading commit data...
incremental-marking.cc Loading commit data...
incremental-marking.h Loading commit data...
mark-compact-inl.h Loading commit data...
mark-compact.cc Loading commit data...
mark-compact.h Loading commit data...
memory-reducer.cc Loading commit data...
memory-reducer.h Loading commit data...
object-stats.cc Loading commit data...
object-stats.h Loading commit data...
objects-visiting-inl.h Loading commit data...
objects-visiting.cc Loading commit data...
objects-visiting.h Loading commit data...
scavenge-job.cc Loading commit data...
scavenge-job.h Loading commit data...
scavenger-inl.h Loading commit data...
scavenger.cc Loading commit data...
scavenger.h Loading commit data...
slots-buffer.cc Loading commit data...
slots-buffer.h Loading commit data...
spaces-inl.h Loading commit data...
spaces.cc Loading commit data...
spaces.h Loading commit data...
store-buffer-inl.h Loading commit data...
store-buffer.cc Loading commit data...
store-buffer.h Loading commit data...