OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 #if defined(OS_MACOSX) | 5 #if defined(OS_MACOSX) |
6 #include <signal.h> | 6 #include <signal.h> |
7 #include <unistd.h> | 7 #include <unistd.h> |
8 #endif // OS_MACOSX | 8 #endif // OS_MACOSX |
9 | 9 |
10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
122 } | 122 } |
123 | 123 |
124 private: | 124 private: |
125 base::TimeTicks begin_process_message_; | 125 base::TimeTicks begin_process_message_; |
126 base::Histogram* const process_times_; | 126 base::Histogram* const process_times_; |
127 DISALLOW_COPY_AND_ASSIGN(RendererMessageLoopObserver); | 127 DISALLOW_COPY_AND_ASSIGN(RendererMessageLoopObserver); |
128 }; | 128 }; |
129 | 129 |
130 // mainline routine for running as the Renderer process | 130 // mainline routine for running as the Renderer process |
131 int RendererMain(const MainFunctionParams& parameters) { | 131 int RendererMain(const MainFunctionParams& parameters) { |
132 TRACE_EVENT_BEGIN_ETW("RendererMain", 0, ""); | 132 TRACE_EVENT_BEGIN("RendererMain", 0, ""); |
133 | 133 |
134 const CommandLine& parsed_command_line = parameters.command_line_; | 134 const CommandLine& parsed_command_line = parameters.command_line_; |
135 base::mac::ScopedNSAutoreleasePool* pool = parameters.autorelease_pool_; | 135 base::mac::ScopedNSAutoreleasePool* pool = parameters.autorelease_pool_; |
136 | 136 |
137 #if defined(OS_MACOSX) | 137 #if defined(OS_MACOSX) |
138 InstallFrameworkHacks(); | 138 InstallFrameworkHacks(); |
139 #endif // OS_MACOSX | 139 #endif // OS_MACOSX |
140 | 140 |
141 #if defined(OS_CHROMEOS) | 141 #if defined(OS_CHROMEOS) |
142 // As Zygote process starts up earlier than browser process gets its own | 142 // As Zygote process starts up earlier than browser process gets its own |
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
224 render_process.set_main_thread(new RenderThread()); | 224 render_process.set_main_thread(new RenderThread()); |
225 #endif | 225 #endif |
226 | 226 |
227 platform.RunSandboxTests(); | 227 platform.RunSandboxTests(); |
228 | 228 |
229 startup_timer.Stop(); // End of Startup Time Measurement. | 229 startup_timer.Stop(); // End of Startup Time Measurement. |
230 | 230 |
231 if (run_loop) { | 231 if (run_loop) { |
232 if (pool) | 232 if (pool) |
233 pool->Recycle(); | 233 pool->Recycle(); |
234 TRACE_EVENT_BEGIN_ETW("RendererMain.START_MSG_LOOP", 0, 0); | 234 TRACE_EVENT_BEGIN("RendererMain.START_MSG_LOOP", 0, 0); |
235 MessageLoop::current()->Run(); | 235 MessageLoop::current()->Run(); |
236 TRACE_EVENT_END_ETW("RendererMain.START_MSG_LOOP", 0, 0); | 236 TRACE_EVENT_END("RendererMain.START_MSG_LOOP", 0, 0); |
237 } | 237 } |
238 } | 238 } |
239 platform.PlatformUninitialize(); | 239 platform.PlatformUninitialize(); |
240 TRACE_EVENT_END_ETW("RendererMain", 0, ""); | 240 TRACE_EVENT_END("RendererMain", 0, ""); |
241 return 0; | 241 return 0; |
242 } | 242 } |
OLD | NEW |