• Peter Marshall's avatar
    [cpu-profiler] Only store deopt inline frames for functions that need it · 0bfcbdd4
    Peter Marshall authored
    We store deopt inline frames for all functions when we receive the code
    creation event. We only ever use this information for code which is
    deoptimized. Given that we receive code deopt events, we can just store
    this information when the code is deoptimized.
    
    At the time of the code deopt event, we also know the associated
    deopt_id. That means we don't need to store a map of deopt_ids to
    vectors of frames, because we will only ever access the frames for the
    deopt_id that is already set.
    
    This means we store way less data, particularly for long-running
    processes which see fewer deopts. This saves 10MiB peak memory on the
    node server example.
    
    Bug: v8:7719
    Change-Id: If6cf5ec413848e4c9f3c1e2106366ae2adae6fb1
    Reviewed-on: https://chromium-review.googlesource.com/1050289
    Commit-Queue: Peter Marshall <petermarshall@chromium.org>
    Reviewed-by: 's avatarAlexei Filippov <alph@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#53330}
    0bfcbdd4
cpu-profiler-inl.h 1.96 KB