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

Side by Side Diff: content/browser/gpu/gpu_process_host.cc

Issue 780133002: Add optimization for CHROMIUM_subscribe_uniform extension. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: piman@ review Created 6 years 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
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 "content/browser/gpu/gpu_process_host.h" 5 #include "content/browser/gpu/gpu_process_host.h"
6 6
7 #include "base/base64.h" 7 #include "base/base64.h"
8 #include "base/base_switches.h" 8 #include "base/base_switches.h"
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 564 matching lines...) Expand 10 before | Expand all | Expand 10 after
575 IPC_MESSAGE_HANDLER(GpuHostMsg_GpuMemoryUmaStats, 575 IPC_MESSAGE_HANDLER(GpuHostMsg_GpuMemoryUmaStats,
576 OnGpuMemoryUmaStatsReceived) 576 OnGpuMemoryUmaStatsReceived)
577 #if defined(OS_MACOSX) 577 #if defined(OS_MACOSX)
578 IPC_MESSAGE_HANDLER_GENERIC(GpuHostMsg_AcceleratedSurfaceBuffersSwapped, 578 IPC_MESSAGE_HANDLER_GENERIC(GpuHostMsg_AcceleratedSurfaceBuffersSwapped,
579 OnAcceleratedSurfaceBuffersSwapped(message)) 579 OnAcceleratedSurfaceBuffersSwapped(message))
580 #endif 580 #endif
581 IPC_MESSAGE_HANDLER(GpuHostMsg_DestroyChannel, 581 IPC_MESSAGE_HANDLER(GpuHostMsg_DestroyChannel,
582 OnDestroyChannel) 582 OnDestroyChannel)
583 IPC_MESSAGE_HANDLER(GpuHostMsg_CacheShader, 583 IPC_MESSAGE_HANDLER(GpuHostMsg_CacheShader,
584 OnCacheShader) 584 OnCacheShader)
585
586 IPC_MESSAGE_UNHANDLED(RouteOnUIThread(message)) 585 IPC_MESSAGE_UNHANDLED(RouteOnUIThread(message))
587 IPC_END_MESSAGE_MAP() 586 IPC_END_MESSAGE_MAP()
588 587
589 return true; 588 return true;
590 } 589 }
591 590
592 void GpuProcessHost::OnChannelConnected(int32 peer_pid) { 591 void GpuProcessHost::OnChannelConnected(int32 peer_pid) {
593 TRACE_EVENT0("gpu", "GpuProcessHost::OnChannelConnected"); 592 TRACE_EVENT0("gpu", "GpuProcessHost::OnChannelConnected");
594 593
595 while (!queued_messages_.empty()) { 594 while (!queued_messages_.empty()) {
(...skipping 467 matching lines...) Expand 10 before | Expand all | Expand 10 after
1063 TRACE_EVENT0("gpu", "GpuProcessHost::OnCacheShader"); 1062 TRACE_EVENT0("gpu", "GpuProcessHost::OnCacheShader");
1064 ClientIdToShaderCacheMap::iterator iter = 1063 ClientIdToShaderCacheMap::iterator iter =
1065 client_id_to_shader_cache_.find(client_id); 1064 client_id_to_shader_cache_.find(client_id);
1066 // If the cache doesn't exist then this is an off the record profile. 1065 // If the cache doesn't exist then this is an off the record profile.
1067 if (iter == client_id_to_shader_cache_.end()) 1066 if (iter == client_id_to_shader_cache_.end())
1068 return; 1067 return;
1069 iter->second->Cache(GetShaderPrefixKey() + ":" + key, shader); 1068 iter->second->Cache(GetShaderPrefixKey() + ":" + key, shader);
1070 } 1069 }
1071 1070
1072 } // namespace content 1071 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698