Handle context loss in VizProcessContextProvider.
Register a context loss callback with the GLES2Implementation to find out about lost context. Implement AddObserver() and RemoveObserver() for VizProcessContextProvider to notify the observers on context loss. viz::Display is already registered as the context loss observer for the ContextProvider. It gets notified and calls out to DisplayClient. Implement a handler for DisplayOutputSurfaceLost() so the root CompositorFrameSink shuts down the display on context loss. The client will see a connection error and reinitialize the display. Also make VizProcessContextProvider log UMA on context loss. This requires moving ContextLossReason enum somewhere visible to VizProcessContextProvider and adding a new histogram for GPU.ContextLost.DisplayCompositor. Bug: 859068 Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_optional_gpu_tests_rel;luci.chromium.try:mac_optional_gpu_tests_rel;luci.chromium.try:win_optional_gpu_tests_rel Change-Id: I4c1fb6f00a893003e9b65dde1a7c5802a8f27692 Reviewed-on: https://chromium-review.googlesource.com/1126482Reviewed-by:Antoine Labour <piman@chromium.org> Reviewed-by:
Sadrul Chowdhury <sadrul@chromium.org> Reviewed-by:
Robert Kaplow (slow) <rkaplow@chromium.org> Commit-Queue: kylechar <kylechar@chromium.org> Cr-Commit-Position: refs/heads/master@{#575016}
Showing
Please register or sign in to comment