• kylechar's avatar
    Add restart_id to BeginFrameSource::source_id_. · 2794bb13
    kylechar authored
    When running with --enable-viz the display compositor is relocated to
    the GPU process. When the GPU process crashes the display compositor is
    restarted and the BeginFrameSource for each viz::Display is recreated.
    This leads to a problem where |source_id_| gets reused and
    BeginFrameObservers DCHECK on a BeginFrameArgs with the same source_id
    but reset sequence_number.
    
    Combine a 32 bit atomic sequence and 32 bit |restart_id| to get the
    BeginFrameSource::source_id_. Only BeginFrameSources used in the GPU
    need this functionality, so |restart_id| is only plumbed through for
    DelayBasedBeginFrameSource. Other BeginFrameSources use
    kNotRestartableId. It will be used in a followup CL from
    GpuDisplayProvider.
    
    Bug: 782268
    Cq-Include-Trybots: master.tryserver.blink:linux_trusty_blink_rel
    Change-Id: I1ef924f43e5fc21a70a0dc96a756929db60626af
    Reviewed-on: https://chromium-review.googlesource.com/755893
    Commit-Queue: kylechar <kylechar@chromium.org>
    Reviewed-by: default avatarAntoine Labour <piman@chromium.org>
    Reviewed-by: default avatarBo <boliu@chromium.org>
    Reviewed-by: default avatarBrian Anderson <brianderson@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#517097}
    2794bb13
gpu_display_provider.cc 4.52 KB