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

Unified Diff: chrome/browser/gpu_process_host.cc

Issue 6340004: Linux: --single-process with GPU acceleration. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Try rebasing off of ToT. Created 9 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « app/gfx/gl/gl_context_linux.cc ('k') | chrome/gpu/gpu_channel.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/gpu_process_host.cc
diff --git a/chrome/browser/gpu_process_host.cc b/chrome/browser/gpu_process_host.cc
index 9c2f0dc396a2f8c2491c8e00c757adaba22c6c23..52d7fd421f0f610e825776de423383655a142652 100644
--- a/chrome/browser/gpu_process_host.cc
+++ b/chrome/browser/gpu_process_host.cc
@@ -574,26 +574,23 @@ bool GpuProcessHost::CanLaunchGpuProcess() const {
bool GpuProcessHost::LaunchGpuProcess() {
const CommandLine& browser_command_line = *CommandLine::ForCurrentProcess();
- // TODO(apatrick): This cannot be a UI message pump on Linux because glib is
- // not thread safe. Changing this to an IO message pump does not completely
- // resolve the problem, most likely because we're sharing a connection to the
- // X server with the browser.
-#if !defined(OS_LINUX)
-
// If the single-process switch is present, just launch the GPU service in a
// new thread in the browser process.
if (browser_command_line.HasSwitch(switches::kSingleProcess)) {
GpuMainThread* thread = new GpuMainThread(channel_id());
base::Thread::Options options;
+#if defined(OS_LINUX)
+ options.message_loop_type = MessageLoop::TYPE_IO;
+#else
options.message_loop_type = MessageLoop::TYPE_UI;
+#endif
if (!thread->StartWithOptions(options))
return false;
return true;
}
-#endif
CommandLine::StringType gpu_launcher =
browser_command_line.GetSwitchValueNative(switches::kGpuLauncher);
« no previous file with comments | « app/gfx/gl/gl_context_linux.cc ('k') | chrome/gpu/gpu_channel.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698