summaryrefslogtreecommitdiffstats
path: root/gpu
diff options
context:
space:
mode:
authordyen <dyen@chromium.org>2015-06-15 11:15:43 -0700
committerCommit bot <commit-bot@chromium.org>2015-06-15 18:16:23 +0000
commitaca37b0fe861108a7a6317d777d5ee527f07364c (patch)
treeda2d8357a957b02dd01a82a822741406e6761697 /gpu
parent391084974c6aa14c68a66f5c382421d95d9cecfd (diff)
downloadchromium_src-aca37b0fe861108a7a6317d777d5ee527f07364c.zip
chromium_src-aca37b0fe861108a7a6317d777d5ee527f07364c.tar.gz
chromium_src-aca37b0fe861108a7a6317d777d5ee527f07364c.tar.bz2
Converted some GPU driver workarounds to use disabled_extensions.
R=sievers@chromium.org, zmo@chromium.org BUG=482067 Review URL: https://codereview.chromium.org/1143823002 Cr-Commit-Position: refs/heads/master@{#334410}
Diffstat (limited to 'gpu')
-rw-r--r--gpu/command_buffer/service/feature_info.cc24
-rw-r--r--gpu/command_buffer/service/feature_info_unittest.cc10
-rw-r--r--gpu/config/gpu_driver_bug_list_json.cc60
-rw-r--r--gpu/config/gpu_driver_bug_workaround_type.h10
4 files changed, 36 insertions, 68 deletions
diff --git a/gpu/command_buffer/service/feature_info.cc b/gpu/command_buffer/service/feature_info.cc
index 5011485..99fa5c4 100644
--- a/gpu/command_buffer/service/feature_info.cc
+++ b/gpu/command_buffer/service/feature_info.cc
@@ -701,10 +701,9 @@ void FeatureInfo::InitializeFeatures() {
validators_.render_buffer_format.AddValue(GL_DEPTH_COMPONENT24);
}
- if (!workarounds_.disable_oes_standard_derivatives &&
- (gl_version_info_->is_es3 ||
- extensions.Contains("GL_OES_standard_derivatives") ||
- gfx::HasDesktopGLFeatures())) {
+ if (gl_version_info_->is_es3 ||
+ extensions.Contains("GL_OES_standard_derivatives") ||
+ gfx::HasDesktopGLFeatures()) {
AddExtensionString("GL_OES_standard_derivatives");
feature_flags_.oes_standard_derivatives = true;
validators_.hint_target.AddValue(GL_FRAGMENT_SHADER_DERIVATIVE_HINT_OES);
@@ -838,10 +837,9 @@ void FeatureInfo::InitializeFeatures() {
bool have_arb_occlusion_query =
extensions.Contains("GL_ARB_occlusion_query");
- if (!workarounds_.disable_ext_occlusion_query &&
- (have_ext_occlusion_query_boolean ||
- have_arb_occlusion_query2 ||
- have_arb_occlusion_query)) {
+ if (have_ext_occlusion_query_boolean ||
+ have_arb_occlusion_query2 ||
+ have_arb_occlusion_query) {
AddExtensionString("GL_EXT_occlusion_query_boolean");
feature_flags_.occlusion_query_boolean = true;
feature_flags_.use_arb_occlusion_query2_for_occlusion_query_boolean =
@@ -925,16 +923,6 @@ void FeatureInfo::InitializeFeatures() {
feature_flags_.ext_shader_texture_lod = true;
}
-#if !defined(OS_MACOSX)
- if (workarounds_.disable_egl_khr_fence_sync) {
- gfx::g_driver_egl.ext.b_EGL_KHR_fence_sync = false;
- }
- if (workarounds_.disable_egl_khr_wait_sync) {
- gfx::g_driver_egl.ext.b_EGL_KHR_wait_sync = false;
- }
-#endif
- if (workarounds_.disable_arb_sync)
- gfx::g_driver_gl.ext.b_GL_ARB_sync = false;
bool ui_gl_fence_works = gfx::GLFence::IsSupported();
UMA_HISTOGRAM_BOOLEAN("GPU.FenceSupport", ui_gl_fence_works);
diff --git a/gpu/command_buffer/service/feature_info_unittest.cc b/gpu/command_buffer/service/feature_info_unittest.cc
index 7fc5c4f..ecb01779 100644
--- a/gpu/command_buffer/service/feature_info_unittest.cc
+++ b/gpu/command_buffer/service/feature_info_unittest.cc
@@ -1173,16 +1173,6 @@ TEST_P(FeatureInfoTest, InitializeWithPreferredEXTDrawBuffers) {
EXPECT_TRUE(info_->feature_flags().ext_draw_buffers);
}
-TEST_P(FeatureInfoTest, ARBSyncDisabled) {
- base::CommandLine command_line(0, NULL);
- command_line.AppendSwitchASCII(
- switches::kGpuDriverBugWorkarounds,
- base::IntToString(gpu::DISABLE_ARB_SYNC));
- SetupInitExpectationsWithCommandLine("GL_ARB_sync", command_line);
- EXPECT_FALSE(info_->feature_flags().chromium_sync_query);
- EXPECT_FALSE(gfx::GLFence::IsSupported());
-}
-
TEST_P(FeatureInfoTest, BlendEquationAdvancedDisabled) {
base::CommandLine command_line(0, NULL);
command_line.AppendSwitchASCII(
diff --git a/gpu/config/gpu_driver_bug_list_json.cc b/gpu/config/gpu_driver_bug_list_json.cc
index 6544088..28c102c0 100644
--- a/gpu/config/gpu_driver_bug_list_json.cc
+++ b/gpu/config/gpu_driver_bug_list_json.cc
@@ -19,7 +19,7 @@ const char kGpuDriverBugListJson[] = LONG_STRING_CONST(
{
"name": "gpu driver bug list",
// Please update the version number whenever you change this file.
- "version": "8.12",
+ "version": "8.13",
"entries": [
{
"id": 1,
@@ -235,8 +235,9 @@ const char kGpuDriverBugListJson[] = LONG_STRING_CONST(
"type": "linux"
},
"vendor_id": "0x8086",
- "features": [
- "disable_ext_occlusion_query"
+ "disabled_extensions": [
+ "GL_ARB_occlusion_query2",
+ "GL_ARB_occlusion_query"
]
},
{
@@ -309,8 +310,8 @@ const char kGpuDriverBugListJson[] = LONG_STRING_CONST(
},
"vendor_id": "0x8086",
"device_id": ["0xa011", "0xa012"],
- "features": [
- "disable_oes_standard_derivatives"
+ "disabled_extensions": [
+ "GL_OES_standard_derivatives"
]
},
{
@@ -814,8 +815,8 @@ const char kGpuDriverBugListJson[] = LONG_STRING_CONST(
"type": "android"
},
"gl_extensions": ".*GL_VIV_shader_binary.*",
- "features": [
- "disable_oes_standard_derivatives"
+ "disabled_extensions": [
+ "GL_OES_standard_derivatives"
]
},
{
@@ -850,8 +851,8 @@ LONG_STRING_CONST(
}
},
"gl_vendor": "Qualcomm.*",
- "features": [
- "disable_egl_khr_fence_sync"
+ "disabled_extensions": [
+ "EGL_KHR_fence_sync"
]
},
{
@@ -883,8 +884,8 @@ LONG_STRING_CONST(
}
},
"gl_vendor": "Imagination Technologies.*",
- "features": [
- "disable_egl_khr_fence_sync"
+ "disabled_extensions": [
+ "EGL_KHR_fence_sync"
]
},
{
@@ -905,8 +906,8 @@ LONG_STRING_CONST(
"op": "<",
"value": "3.0"
},
- "features": [
- "disable_egl_khr_fence_sync"
+ "disabled_extensions": [
+ "EGL_KHR_fence_sync"
]
},
{
@@ -921,8 +922,8 @@ LONG_STRING_CONST(
}
},
"gl_vendor": "Broadcom.*",
- "features": [
- "disable_egl_khr_fence_sync"
+ "disabled_extensions": [
+ "EGL_KHR_fence_sync"
]
},
{
@@ -1064,8 +1065,8 @@ LONG_STRING_CONST(
"op": "=",
"value": "3.1"
},
- "features": [
- "disable_egl_khr_wait_sync"
+ "disabled_extensions": [
+ "EGL_KHR_wait_sync"
]
},
{
@@ -1193,7 +1194,7 @@ LONG_STRING_CONST(
},
{
"id": 104,
- "description": "EXT_occlusion_query hangs on MediaTek MT8135 pre-Lollipop",
+ "description": "EXT_occlusion_query_boolean hangs on MediaTek MT8135 pre-Lollipop",
"os": {
"type": "android",
"version": {
@@ -1203,8 +1204,8 @@ LONG_STRING_CONST(
},
"gl_vendor": "Imagination.*",
"gl_renderer": "PowerVR Rogue Han",
- "features": [
- "disable_ext_occlusion_query"
+ "disabled_extensions": [
+ "GL_EXT_occlusion_query_boolean"
]
},
{
@@ -1221,17 +1222,14 @@ LONG_STRING_CONST(
},
{
"id": 106,
- "description": "EXT_occlusion_query hangs on PowerVR SGX 544 (IMG) drivers",
+ "description": "EXT_occlusion_query_boolean hangs on PowerVR SGX 544 (IMG) drivers",
"os": {
"type": "android"
},
"gl_vendor": "Imagination.*",
"gl_renderer": "PowerVR SGX 544",
- "features": [
- "disable_ext_occlusion_query"
- ],
"disabled_extensions": [
- "EXT_occlusion_query_boolean"
+ "GL_EXT_occlusion_query_boolean"
]
},
{
@@ -1254,8 +1252,10 @@ LONG_STRING_CONST(
"value2": "1.4"
},
"features": [
- "avoid_egl_image_target_texture_reuse",
- "disable_egl_khr_wait_sync"
+ "avoid_egl_image_target_texture_reuse"
+ ],
+ "disabled_extensions": [
+ "EGL_KHR_wait_sync"
]
},
{
@@ -1291,8 +1291,8 @@ LONG_STRING_CONST(
"op": "<",
"value": "95"
},
- "features": [
- "disable_egl_khr_wait_sync"
+ "disabled_extensions": [
+ "EGL_KHR_wait_sync"
]
},
{
@@ -1328,7 +1328,7 @@ LONG_STRING_CONST(
{
"id": 113,
"cr_bugs": [477514],
- "description": "EXT_disjoint_timer_query fails after 2 queries on adreno 420",
+ "description": "EXT_disjoint_timer_query fails after 256 queries on adreno 420",
"os": {
"type": "android"
},
diff --git a/gpu/config/gpu_driver_bug_workaround_type.h b/gpu/config/gpu_driver_bug_workaround_type.h
index 864b155..9cf6d05 100644
--- a/gpu/config/gpu_driver_bug_workaround_type.h
+++ b/gpu/config/gpu_driver_bug_workaround_type.h
@@ -20,8 +20,6 @@
count_all_in_varyings_packing) \
GPU_OP(DISABLE_ANGLE_INSTANCED_ARRAYS, \
disable_angle_instanced_arrays) \
- GPU_OP(DISABLE_ARB_SYNC, \
- disable_arb_sync) \
GPU_OP(DISABLE_ASYNC_READPIXELS, \
disable_async_readpixels) \
GPU_OP(DISABLE_BLEND_EQUATION_ADVANCED, \
@@ -32,24 +30,16 @@
disable_d3d11) \
GPU_OP(DISABLE_DEPTH_TEXTURE, \
disable_depth_texture) \
- GPU_OP(DISABLE_EGL_KHR_FENCE_SYNC, \
- disable_egl_khr_fence_sync) \
- GPU_OP(DISABLE_EGL_KHR_WAIT_SYNC, \
- disable_egl_khr_wait_sync) \
GPU_OP(DISABLE_DISCARD_FRAMEBUFFER, \
disable_discard_framebuffer) \
GPU_OP(DISABLE_EXT_DRAW_BUFFERS, \
disable_ext_draw_buffers) \
- GPU_OP(DISABLE_EXT_OCCLUSION_QUERY, \
- disable_ext_occlusion_query) \
GPU_OP(DISABLE_GL_RGB_FORMAT, \
disable_gl_rgb_format) \
GPU_OP(DISABLE_MULTIMONITOR_MULTISAMPLING, \
disable_multimonitor_multisampling) \
GPU_OP(DISABLE_MULTISAMPLED_RENDER_TO_TEXTURE, \
disable_multisampled_render_to_texture) \
- GPU_OP(DISABLE_OES_STANDARD_DERIVATIVES, \
- disable_oes_standard_derivatives) \
GPU_OP(DISABLE_POST_SUB_BUFFERS_FOR_ONSCREEN_SURFACES, \
disable_post_sub_buffers_for_onscreen_surfaces) \
GPU_OP(ETC1_POWER_OF_TWO_ONLY, \