• ruuda's avatar
    [Tracing] Enable heap dumps with both type info and backtraces · 3314e2e3
    ruuda authored
    This is a major change to |HeapDumpWriter| which enables it to dump the
    format described in https://goo.gl/KY7zVE. This will allow the heap
    profiler to break down the heap by type or backtrace, but also
    combinations of those.
    
    This changes the interface of |HeapDumpWriter| slightly from a two-step
    process (insert allocations, dump json) to a three-step process (insert
    allocations, compute what to dump, convert to json). The main reason for
    doing this is testability. Aggregation and json conversion are now
    completely orthogonal. This means that the aggregation algorithm can be
    tested without having to parse the json first, and the json conversion
    is simpler to test too.
    
    This is part of the heap profiler in chrome://tracing.
    
    BUG=524631
    
    Review URL: https://codereview.chromium.org/1494293005
    
    Cr-Commit-Position: refs/heads/master@{#364444}
    3314e2e3
heap_profiler_heap_dump_writer.h 3.76 KB