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

Side by Side Diff: chrome/app/chrome_dll_main.cc

Issue 2003001: Add time for when chrome's main() is called. (Closed)
Patch Set: Created 10 years, 7 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
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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 // TODO(port): the ifdefs in here are a first step towards trying to determine 5 // TODO(port): the ifdefs in here are a first step towards trying to determine
6 // the correct abstraction for all the OS functionality required at this 6 // the correct abstraction for all the OS functionality required at this
7 // stage of process initialization. It should not be taken as a final 7 // stage of process initialization. It should not be taken as a final
8 // abstraction. 8 // abstraction.
9 9
10 #include "build/build_config.h" 10 #include "build/build_config.h"
(...skipping 379 matching lines...) Expand 10 before | Expand all | Expand 10 after
390 390
391 } // namespace 391 } // namespace
392 392
393 #if defined(OS_WIN) 393 #if defined(OS_WIN)
394 DLLEXPORT int __cdecl ChromeMain(HINSTANCE instance, 394 DLLEXPORT int __cdecl ChromeMain(HINSTANCE instance,
395 sandbox::SandboxInterfaceInfo* sandbox_info, 395 sandbox::SandboxInterfaceInfo* sandbox_info,
396 TCHAR* command_line) { 396 TCHAR* command_line) {
397 #elif defined(OS_POSIX) 397 #elif defined(OS_POSIX)
398 int ChromeMain(int argc, char** argv) { 398 int ChromeMain(int argc, char** argv) {
399 #endif 399 #endif
400 400 #if defined(OS_CHROMEOS)
401 // Output our start times.
402 system("set -o noclobber ; cat /proc/uptime > /tmp/uptime-chrome-main");
403 system("set -o noclobber ; cat /sys/block/sda/stat > /tmp/disk-chrome-main");
404 #endif
401 #if defined(OS_MACOSX) 405 #if defined(OS_MACOSX)
402 // TODO(mark): Some of these things ought to be handled in chrome_exe_main.mm. 406 // TODO(mark): Some of these things ought to be handled in chrome_exe_main.mm.
403 // Under the current architecture, nothing in chrome_exe_main can rely 407 // Under the current architecture, nothing in chrome_exe_main can rely
404 // directly on chrome_dll code on the Mac, though, so until some of this code 408 // directly on chrome_dll code on the Mac, though, so until some of this code
405 // is refactored to avoid such a dependency, it lives here. See also the 409 // is refactored to avoid such a dependency, it lives here. See also the
406 // TODO(mark) below at InitCrashReporter() and DestructCrashReporter(). 410 // TODO(mark) below at InitCrashReporter() and DestructCrashReporter().
407 base::EnableTerminationOnHeapCorruption(); 411 base::EnableTerminationOnHeapCorruption();
408 base::EnableTerminationOnOutOfMemory(); 412 base::EnableTerminationOnOutOfMemory();
409 #endif // OS_MACOSX 413 #endif // OS_MACOSX
410 414
(...skipping 418 matching lines...) Expand 10 before | Expand all | Expand 10 after
829 833
830 logging::CleanupChromeLogging(); 834 logging::CleanupChromeLogging();
831 835
832 #if defined(OS_MACOSX) && defined(GOOGLE_CHROME_BUILD) 836 #if defined(OS_MACOSX) && defined(GOOGLE_CHROME_BUILD)
833 // TODO(mark): See the TODO(mark) above at InitCrashReporter. 837 // TODO(mark): See the TODO(mark) above at InitCrashReporter.
834 DestructCrashReporter(); 838 DestructCrashReporter();
835 #endif // OS_MACOSX && GOOGLE_CHROME_BUILD 839 #endif // OS_MACOSX && GOOGLE_CHROME_BUILD
836 840
837 return rv; 841 return rv;
838 } 842 }
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/chromeos/boot_times_loader.h » ('j') | chrome/browser/chromeos/boot_times_loader.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698