Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(264)

Side by Side Diff: gpu/ipc/service/gpu_command_buffer_stub.cc

Issue 1871613002: Compute GpuDriverBugWorkarounds only one time in the GPU process (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « gpu/ipc/service/gpu_channel_manager.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "gpu/ipc/service/gpu_command_buffer_stub.h" 5 #include "gpu/ipc/service/gpu_command_buffer_stub.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/bind_helpers.h" 10 #include "base/bind_helpers.h"
(...skipping 192 matching lines...) Expand 10 before | Expand all | Expand 10 after
203 FastSetActiveURL(active_url_, active_url_hash_, channel_); 203 FastSetActiveURL(active_url_, active_url_hash_, channel_);
204 204
205 gles2::ContextCreationAttribHelper attrib_parser; 205 gles2::ContextCreationAttribHelper attrib_parser;
206 attrib_parser.Parse(requested_attribs_); 206 attrib_parser.Parse(requested_attribs_);
207 207
208 if (share_group) { 208 if (share_group) {
209 context_group_ = share_group->context_group_; 209 context_group_ = share_group->context_group_;
210 DCHECK(context_group_->bind_generates_resource() == 210 DCHECK(context_group_->bind_generates_resource() ==
211 attrib_parser.bind_generates_resource); 211 attrib_parser.bind_generates_resource);
212 } else { 212 } else {
213 scoped_refptr<gles2::FeatureInfo> feature_info = new gles2::FeatureInfo(
214 channel_->gpu_channel_manager()->gpu_driver_bug_workarounds());
213 context_group_ = new gles2::ContextGroup( 215 context_group_ = new gles2::ContextGroup(
214 channel_->gpu_channel_manager()->gpu_preferences(), mailbox_manager, 216 channel_->gpu_channel_manager()->gpu_preferences(), mailbox_manager,
215 new GpuCommandBufferMemoryTracker(channel, 217 new GpuCommandBufferMemoryTracker(channel,
216 command_buffer_id_.GetUnsafeValue()), 218 command_buffer_id_.GetUnsafeValue()),
217 channel_->gpu_channel_manager()->shader_translator_cache(), 219 channel_->gpu_channel_manager()->shader_translator_cache(),
218 channel_->gpu_channel_manager()->framebuffer_completeness_cache(), NULL, 220 channel_->gpu_channel_manager()->framebuffer_completeness_cache(),
219 subscription_ref_set, pending_valuebuffer_state, 221 feature_info, subscription_ref_set, pending_valuebuffer_state,
220 attrib_parser.bind_generates_resource); 222 attrib_parser.bind_generates_resource);
221 } 223 }
222 224
223 // Virtualize PreferIntegratedGpu contexts by default on OS X to prevent 225 // Virtualize PreferIntegratedGpu contexts by default on OS X to prevent
224 // performance regressions when enabling FCM. 226 // performance regressions when enabling FCM.
225 // http://crbug.com/180463 227 // http://crbug.com/180463
226 #if defined(OS_MACOSX) 228 #if defined(OS_MACOSX)
227 if (gpu_preference_ == gfx::PreferIntegratedGpu) 229 if (gpu_preference_ == gfx::PreferIntegratedGpu)
228 use_virtualized_gl_context_ = true; 230 use_virtualized_gl_context_ = true;
229 #endif 231 #endif
(...skipping 897 matching lines...) Expand 10 before | Expand all | Expand 10 after
1127 result)); 1129 result));
1128 } 1130 }
1129 1131
1130 void GpuCommandBufferStub::SendUpdateVSyncParameters(base::TimeTicks timebase, 1132 void GpuCommandBufferStub::SendUpdateVSyncParameters(base::TimeTicks timebase,
1131 base::TimeDelta interval) { 1133 base::TimeDelta interval) {
1132 Send(new GpuCommandBufferMsg_UpdateVSyncParameters(route_id_, timebase, 1134 Send(new GpuCommandBufferMsg_UpdateVSyncParameters(route_id_, timebase,
1133 interval)); 1135 interval));
1134 } 1136 }
1135 1137
1136 } // namespace gpu 1138 } // namespace gpu
OLDNEW
« no previous file with comments | « gpu/ipc/service/gpu_channel_manager.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698