• Sunny Sachanandani's avatar
    gpu: Sync to primary monitor's vblank (windows) · bd0cae50
    Sunny Sachanandani authored
    DWM composition is limited to primary monitor's refresh rate.  Prior to
    GPU vsync we would use DWM composition rate to drive begin frames.
    
    With GPU vsync we started using per monitor vblank to limit begin frames
    in case primary monitor had higher refresh rate, but this might be
    causing draw duration and omnibar latency regressions.  MS platform team
    also suggested syncing to primary monitor only.  In any case the correct
    approach would be to further limit begin frames based on event queries
    from 2 frames back.
    
    This CL makes the GPU vsync begin frames sync to primary monitor, and
    also makes the vsync thread a singleton since it doesn't have per-window
    state any more.
    
    Bug: 953970
    Change-Id: Id3d3f043cb847172b1d6ba4bd38b087ceb2d8631
    Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1711215Reviewed-by: default avatarZhenyao Mo <zmo@chromium.org>
    Commit-Queue: Sunny Sachanandani <sunnyps@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#679832}
    bd0cae50
vsync_observer.h 522 Bytes