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

Side by Side Diff: content/common/gpu/gpu_channel.h

Issue 1463823002: Add DriverBugWorkaroundsInGpuProcessPage to gpu_process_test.py (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: add a testing GpuChannelMsg_GetDriverBugWorkArounds IPC message and use it in a new browser test 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 | « no previous file | content/common/gpu/gpu_channel.cc » ('j') | content/common/gpu/gpu_channel.cc » ('J')
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 #ifndef CONTENT_COMMON_GPU_GPU_CHANNEL_H_ 5 #ifndef CONTENT_COMMON_GPU_GPU_CHANNEL_H_
6 #define CONTENT_COMMON_GPU_GPU_CHANNEL_H_ 6 #define CONTENT_COMMON_GPU_GPU_CHANNEL_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after
166 // Returns the shared sync point global order data for the stream. 166 // Returns the shared sync point global order data for the stream.
167 scoped_refptr<gpu::SyncPointOrderData> GetSyncPointOrderData( 167 scoped_refptr<gpu::SyncPointOrderData> GetSyncPointOrderData(
168 int32_t stream_id); 168 int32_t stream_id);
169 169
170 void PostHandleOutOfOrderMessage(const IPC::Message& message); 170 void PostHandleOutOfOrderMessage(const IPC::Message& message);
171 void PostHandleMessage(const scoped_refptr<GpuChannelMessageQueue>& queue); 171 void PostHandleMessage(const scoped_refptr<GpuChannelMessageQueue>& queue);
172 172
173 // Synchronously handle the message to make testing convenient. 173 // Synchronously handle the message to make testing convenient.
174 void HandleMessageForTesting(const IPC::Message& msg); 174 void HandleMessageForTesting(const IPC::Message& msg);
175 175
176 #if defined(OS_ANDROID)
177 const GpuCommandBufferStub* GetOneStub() const; 176 const GpuCommandBufferStub* GetOneStub() const;
178 #endif
179 177
180 protected: 178 protected:
181 // The message filter on the io thread. 179 // The message filter on the io thread.
182 scoped_refptr<GpuChannelMessageFilter> filter_; 180 scoped_refptr<GpuChannelMessageFilter> filter_;
183 181
184 // Map of routing id to command buffer stub. 182 // Map of routing id to command buffer stub.
185 base::ScopedPtrHashMap<int32_t, scoped_ptr<GpuCommandBufferStub>> stubs_; 183 base::ScopedPtrHashMap<int32_t, scoped_ptr<GpuCommandBufferStub>> stubs_;
186 184
187 private: 185 private:
188 bool OnControlMessageReceived(const IPC::Message& msg); 186 bool OnControlMessageReceived(const IPC::Message& msg);
(...skipping 19 matching lines...) Expand all
208 void AddRouteToStream(int32_t route_id, int32_t stream_id); 206 void AddRouteToStream(int32_t route_id, int32_t stream_id);
209 void RemoveRouteFromStream(int32_t route_id); 207 void RemoveRouteFromStream(int32_t route_id);
210 208
211 // Message handlers for control messages. 209 // Message handlers for control messages.
212 void OnCreateCommandBuffer(gpu::SurfaceHandle surface_handle, 210 void OnCreateCommandBuffer(gpu::SurfaceHandle surface_handle,
213 const gfx::Size& size, 211 const gfx::Size& size,
214 const GPUCreateCommandBufferConfig& init_params, 212 const GPUCreateCommandBufferConfig& init_params,
215 int32_t route_id, 213 int32_t route_id,
216 bool* succeeded); 214 bool* succeeded);
217 void OnDestroyCommandBuffer(int32_t route_id); 215 void OnDestroyCommandBuffer(int32_t route_id);
218 216 void OnGetDriverBugWorkArounds(
217 std::vector<std::string>* gpu_driver_bug_workarounds);
219 218
220 // The lifetime of objects of this class is managed by a GpuChannelManager. 219 // The lifetime of objects of this class is managed by a GpuChannelManager.
221 // The GpuChannelManager destroy all the GpuChannels that they own when they 220 // The GpuChannelManager destroy all the GpuChannels that they own when they
222 // are destroyed. So a raw pointer is safe. 221 // are destroyed. So a raw pointer is safe.
223 GpuChannelManager* const gpu_channel_manager_; 222 GpuChannelManager* const gpu_channel_manager_;
224 223
225 // Sync point manager. Outlives the channel and is guaranteed to outlive the 224 // Sync point manager. Outlives the channel and is guaranteed to outlive the
226 // message loop. 225 // message loop.
227 gpu::SyncPointManager* const sync_point_manager_; 226 gpu::SyncPointManager* const sync_point_manager_;
228 227
(...skipping 245 matching lines...) Expand 10 before | Expand all | Expand 10 after
474 scoped_refptr<gpu::PreemptionFlag> preempting_flag_; 473 scoped_refptr<gpu::PreemptionFlag> preempting_flag_;
475 scoped_refptr<gpu::PreemptionFlag> preempted_flag_; 474 scoped_refptr<gpu::PreemptionFlag> preempted_flag_;
476 gpu::SyncPointManager* const sync_point_manager_; 475 gpu::SyncPointManager* const sync_point_manager_;
477 476
478 DISALLOW_COPY_AND_ASSIGN(GpuChannelMessageQueue); 477 DISALLOW_COPY_AND_ASSIGN(GpuChannelMessageQueue);
479 }; 478 };
480 479
481 } // namespace content 480 } // namespace content
482 481
483 #endif // CONTENT_COMMON_GPU_GPU_CHANNEL_H_ 482 #endif // CONTENT_COMMON_GPU_GPU_CHANNEL_H_
OLDNEW
« no previous file with comments | « no previous file | content/common/gpu/gpu_channel.cc » ('j') | content/common/gpu/gpu_channel.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698