• Eric Karl's avatar
    Revert "Android OOP-D: DisplayScheduler should only report draw-inducing damage" · c027fd37
    Eric Karl authored
    This reverts commit 60d359fd.
    
    Reason for revert: This logic could still be flaky (what if we go invisible after deferring commits), and isn't needed after https://chromium-review.googlesource.com/c/chromium/src/+/1184376, so let's revert.
    
    Original change's description:
    > Android OOP-D: DisplayScheduler should only report draw-inducing damage
    > 
    > Currently DisplayScheduler reports damage to SurfaceManager in any case
    > where a damaged surface ID damages the display. While these cases will
    > trigger a draw when visible, they don't necessarily trigger a draw
    > in any defined timeframe. This can lead to issues. Consider:
    > 
    > 1) Display 1 is not visible, embeds surface A.
    > 2) Surface A sends CF 1, we don't immediately ack as we will wait for
    >    Display 1 to draw.
    > 3) Display 2 becomes visible, embeds surface A with a new surface ID.
    > 4) Display 2 will never update, as no new frames will be produced for
    >    surface A as the renderer is continually waiting on the ack for
    >    CF 1.
    > 
    > By having DisplayScheduler report no damage if invisible, we always
    > ack frames in a timely manner. This may allow a renderer to produce
    > some extra frames when its display is invisible, but this should be
    > limited as the renderer itself receives visibility notifications and
    > won't get additional BeginFrames once visibility is fully processed.
    > 
    > Bug: 875895
    > Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel
    > Change-Id: I272de950d8e4d4c819c445dc8162ac360afb80a1
    > Reviewed-on: https://chromium-review.googlesource.com/1182862
    > Reviewed-by: Fady Samuel <fsamuel@chromium.org>
    > Commit-Queue: Eric Karl <ericrk@chromium.org>
    > Cr-Commit-Position: refs/heads/master@{#584917}
    
    TBR=fsamuel@chromium.org,ericrk@chromium.org
    
    # Not skipping CQ checks because original CL landed > 1 day ago.
    
    Bug: 875895
    Change-Id: Idefad0b80d08b3c9fecf655b27b3c6ffb85eca10
    Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel
    Reviewed-on: https://chromium-review.googlesource.com/1232335Reviewed-by: default avatarEric Karl <ericrk@chromium.org>
    Commit-Queue: Eric Karl <ericrk@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#593003}
    c027fd37
surface_observer.h 2.87 KB