OLD | NEW |
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/bind.h" | 9 #include "base/bind.h" |
10 #include "base/bind_helpers.h" | 10 #include "base/bind_helpers.h" |
(...skipping 1177 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1188 | 1188 |
1189 // If specified, prepend a launcher program to the command line. | 1189 // If specified, prepend a launcher program to the command line. |
1190 if (!gpu_launcher.empty()) | 1190 if (!gpu_launcher.empty()) |
1191 cmd_line->PrependWrapper(gpu_launcher); | 1191 cmd_line->PrependWrapper(gpu_launcher); |
1192 | 1192 |
1193 process_->Launch( | 1193 process_->Launch( |
1194 #if defined(OS_WIN) | 1194 #if defined(OS_WIN) |
1195 new GpuSandboxedProcessLauncherDelegate(cmd_line), | 1195 new GpuSandboxedProcessLauncherDelegate(cmd_line), |
1196 #elif defined(OS_POSIX) | 1196 #elif defined(OS_POSIX) |
1197 false, | 1197 false, |
1198 base::EnvironmentVector(), | 1198 base::EnvironmentMap(), |
1199 #endif | 1199 #endif |
1200 cmd_line); | 1200 cmd_line); |
1201 process_launched_ = true; | 1201 process_launched_ = true; |
1202 | 1202 |
1203 UMA_HISTOGRAM_ENUMERATION("GPU.GPUProcessLifetimeEvents", | 1203 UMA_HISTOGRAM_ENUMERATION("GPU.GPUProcessLifetimeEvents", |
1204 LAUNCHED, GPU_PROCESS_LIFETIME_EVENT_MAX); | 1204 LAUNCHED, GPU_PROCESS_LIFETIME_EVENT_MAX); |
1205 return true; | 1205 return true; |
1206 } | 1206 } |
1207 | 1207 |
1208 void GpuProcessHost::SendOutstandingReplies() { | 1208 void GpuProcessHost::SendOutstandingReplies() { |
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1276 TRACE_EVENT0("gpu", "GpuProcessHost::OnCacheShader"); | 1276 TRACE_EVENT0("gpu", "GpuProcessHost::OnCacheShader"); |
1277 ClientIdToShaderCacheMap::iterator iter = | 1277 ClientIdToShaderCacheMap::iterator iter = |
1278 client_id_to_shader_cache_.find(client_id); | 1278 client_id_to_shader_cache_.find(client_id); |
1279 // If the cache doesn't exist then this is an off the record profile. | 1279 // If the cache doesn't exist then this is an off the record profile. |
1280 if (iter == client_id_to_shader_cache_.end()) | 1280 if (iter == client_id_to_shader_cache_.end()) |
1281 return; | 1281 return; |
1282 iter->second->Cache(GetShaderPrefixKey() + ":" + key, shader); | 1282 iter->second->Cache(GetShaderPrefixKey() + ":" + key, shader); |
1283 } | 1283 } |
1284 | 1284 |
1285 } // namespace content | 1285 } // namespace content |
OLD | NEW |