New issue
Advanced search Search tips

Issue 781084 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Nov 2017
Cc:
EstimatedDays: ----
NextAction: ----
OS: Android
Pri: 3
Type: Bug



Sign in to add a comment

OOP raster on android can't create GrContext.

Project Member Reported by vmp...@chromium.org, Nov 3 2017

Issue description

There are two things happening on android with oop raster:

1. We fail to create a GrContext, so we can't create a decoder:

[ERROR:gles2_cmd_decoder.cc(3765)] ContextResult::kFatalFailure: Could not create GrContext
[ERROR:gpu_command_buffer_stub.cc(806)] Failed to initialize decoder.
[ERROR:gpu_channel.cc(626)] GpuChannel::CreateCommandBuffer(): failed to initialize GpuCommandBufferStub
[ERROR:command_buffer_proxy_impl.cc(142)] Failure processing GpuChannelMsg_CreateCommandBuffer.
[ERROR:context_provider_command_buffer.cc(245)] GpuChannelHost failed to create command buffer.
[INFO:GrGLInterface.cpp(827)] ../../third_party/skia/src/gpu/gl/GrGLInterface.cpp:827 GrGLInterface::validate() failed.

And 2. this error just keep happening so the page look like it's frozen. Should we have a fallback that eventually gives up and does regular gpu rasterization?

The first failure is in the GrGLInterface validation here:
https://cs.chromium.org/chromium/src/third_party/skia/src/gpu/gl/GrGLInterface.cpp?q=third_party/skia/src/gpu/gl/GrGLInterface.cpp&sq=package:chromium&l=827

Although, it's a different error, it does look similar to  issue 780320 . piman@ do you know if there's a fix here that would be similar, or is this an entirely different thing?

This is blocking pixel tests patch since android bots fail with the same error.
 

Comment 1 by piman@chromium.org, Nov 3 2017

AFAICT we have the function bindings for those 3 functions, but we don't set them in CreateGrGLInterface, so that should be an easy fix.

Re #2, I think there's 2 options:
A- have retry logic to try recreating the context without OOP raster support if it fails (no need to retry N times if fatal failure, just fall back immediately). 
B- succeed creating the context anyway, but without the OOP raster capabilities. We would probably want to add a bit in gpu::Capabilities to advertise support.

B seems better for startup time.
Project Member

Comment 2 by bugdroid1@chromium.org, Nov 3 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/9893245dccbbf562ea4db02d9463c87d3b75cffc

commit 9893245dccbbf562ea4db02d9463c87d3b75cffc
Author: Vladimir Levin <vmpstr@chromium.org>
Date: Fri Nov 03 18:43:50 2017

oop: Expose ProgramBinary functions to GrGLInterface.

This patch exposes three functions to the GrGLInterface, which is
required for proper GrContext validation in skia:
- glGetProgramBinary
- glProgramBinary
- glProgramParameteri

R=piman@chromium.org

Bug:  781084 
Cq-Include-Trybots: master.tryserver.chromium.android:android_optional_gpu_tests_rel;master.tryserver.chromium.linux:linux_optional_gpu_tests_rel;master.tryserver.chromium.mac:mac_optional_gpu_tests_rel;master.tryserver.chromium.win:win_optional_gpu_tests_rel
Change-Id: Id2d09f47c01e68f926bd2c66c6871d8e21a41b9a
Reviewed-on: https://chromium-review.googlesource.com/753978
Reviewed-by: Antoine Labour <piman@chromium.org>
Commit-Queue: vmpstr <vmpstr@chromium.org>
Cr-Commit-Position: refs/heads/master@{#513854}
[modify] https://crrev.com/9893245dccbbf562ea4db02d9463c87d3b75cffc/gpu/command_buffer/service/create_gr_gl_interface.cc

Project Member

Comment 3 by bugdroid1@chromium.org, Nov 7 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/1eed797d6ce9dd71390ad3ef04efa9bb73043e6f

commit 1eed797d6ce9dd71390ad3ef04efa9bb73043e6f
Author: Vladimir Levin <vmpstr@chromium.org>
Date: Tue Nov 07 00:24:03 2017

oop: Fail GrContext creation once and fallback to gpu raster.

This patch ensures that if we can't create a GrContext in the gpu
process for oop raster, we fail and fall back to in-process raster.

R=enne@chromium.org, piman@chromium.org

Bug:  781084 
Cq-Include-Trybots: master.tryserver.blink:linux_trusty_blink_rel;master.tryserver.chromium.android:android_optional_gpu_tests_rel;master.tryserver.chromium.linux:linux_optional_gpu_tests_rel;master.tryserver.chromium.mac:mac_optional_gpu_tests_rel;master.tryserver.chromium.win:win_optional_gpu_tests_rel
Change-Id: I2e24a6969b9b960edeceb114d34ad15dac738756
Reviewed-on: https://chromium-review.googlesource.com/754032
Commit-Queue: vmpstr <vmpstr@chromium.org>
Reviewed-by: Antoine Labour <piman@chromium.org>
Reviewed-by: enne <enne@chromium.org>
Reviewed-by: Daniel Cheng <dcheng@chromium.org>
Cr-Commit-Position: refs/heads/master@{#514315}
[modify] https://crrev.com/1eed797d6ce9dd71390ad3ef04efa9bb73043e6f/cc/trees/layer_tree_host_impl.cc
[modify] https://crrev.com/1eed797d6ce9dd71390ad3ef04efa9bb73043e6f/gpu/command_buffer/common/capabilities.h
[modify] https://crrev.com/1eed797d6ce9dd71390ad3ef04efa9bb73043e6f/gpu/command_buffer/service/gles2_cmd_decoder.cc
[modify] https://crrev.com/1eed797d6ce9dd71390ad3ef04efa9bb73043e6f/gpu/ipc/common/gpu_command_buffer_traits_multi.h

Comment 4 by piman@chromium.org, Nov 7 2017

Cc: -vmp...@chromium.org piman@chromium.org
Owner: vmp...@chromium.org
Status: Fixed (was: Assigned)

Sign in to add a comment