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

Side by Side Diff: content/browser/browser_main_loop.cc

Issue 1327063002: [tracing] Add sqlite memory statistics to tracing. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase. Created 5 years, 2 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
« no previous file with comments | « no previous file | sql/BUILD.gn » ('j') | sql/connection.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/browser_main_loop.h" 5 #include "content/browser/browser_main_loop.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/location.h" 9 #include "base/location.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
64 #include "device/battery/battery_status_service.h" 64 #include "device/battery/battery_status_service.h"
65 #include "media/audio/audio_manager.h" 65 #include "media/audio/audio_manager.h"
66 #include "media/base/media.h" 66 #include "media/base/media.h"
67 #include "media/base/user_input_monitor.h" 67 #include "media/base/user_input_monitor.h"
68 #include "media/midi/midi_manager.h" 68 #include "media/midi/midi_manager.h"
69 #include "net/base/network_change_notifier.h" 69 #include "net/base/network_change_notifier.h"
70 #include "net/socket/client_socket_factory.h" 70 #include "net/socket/client_socket_factory.h"
71 #include "net/ssl/ssl_config_service.h" 71 #include "net/ssl/ssl_config_service.h"
72 #include "ipc/mojo/scoped_ipc_support.h" 72 #include "ipc/mojo/scoped_ipc_support.h"
73 #include "skia/ext/skia_memory_dump_provider.h" 73 #include "skia/ext/skia_memory_dump_provider.h"
74 #include "sql/sql_memory_dump_provider.h"
74 #include "ui/base/clipboard/clipboard.h" 75 #include "ui/base/clipboard/clipboard.h"
75 76
76 #if defined(USE_AURA) || (defined(OS_MACOSX) && !defined(OS_IOS)) 77 #if defined(USE_AURA) || (defined(OS_MACOSX) && !defined(OS_IOS))
77 #include "content/browser/compositor/image_transport_factory.h" 78 #include "content/browser/compositor/image_transport_factory.h"
78 #endif 79 #endif
79 80
80 #if defined(USE_AURA) 81 #if defined(USE_AURA)
81 #include "content/public/browser/context_factory.h" 82 #include "content/public/browser/context_factory.h"
82 #include "ui/aura/env.h" 83 #include "ui/aura/env.h"
83 #endif 84 #endif
(...skipping 570 matching lines...) Expand 10 before | Expand all | Expand 10 after
654 TRACE_EVENT0("startup", 655 TRACE_EVENT0("startup",
655 "BrowserMainLoop::Subsystem:EnableAggressiveCommitDelay"); 656 "BrowserMainLoop::Subsystem:EnableAggressiveCommitDelay");
656 DOMStorageArea::EnableAggressiveCommitDelay(); 657 DOMStorageArea::EnableAggressiveCommitDelay();
657 } 658 }
658 659
659 // Enable memory-infra dump providers. 660 // Enable memory-infra dump providers.
660 base::trace_event::MemoryDumpManager::GetInstance()->RegisterDumpProvider( 661 base::trace_event::MemoryDumpManager::GetInstance()->RegisterDumpProvider(
661 HostSharedBitmapManager::current()); 662 HostSharedBitmapManager::current());
662 base::trace_event::MemoryDumpManager::GetInstance()->RegisterDumpProvider( 663 base::trace_event::MemoryDumpManager::GetInstance()->RegisterDumpProvider(
663 skia::SkiaMemoryDumpProvider::GetInstance()); 664 skia::SkiaMemoryDumpProvider::GetInstance());
665 base::trace_event::MemoryDumpManager::GetInstance()->RegisterDumpProvider(
666 sql::SqlMemoryDumpProvider::GetInstance());
Primiano Tucci (use gerrit) 2015/10/08 17:18:20 Don't we need this also in child processes?
ssid 2015/10/08 17:20:17 No, there are no connections opened in child proce
664 667
665 #if defined(TCMALLOC_TRACE_MEMORY_SUPPORTED) 668 #if defined(TCMALLOC_TRACE_MEMORY_SUPPORTED)
666 trace_memory_controller_.reset(new base::trace_event::TraceMemoryController( 669 trace_memory_controller_.reset(new base::trace_event::TraceMemoryController(
667 base::MessageLoop::current()->task_runner(), 670 base::MessageLoop::current()->task_runner(),
668 ::HeapProfilerWithPseudoStackStart, ::HeapProfilerStop, 671 ::HeapProfilerWithPseudoStackStart, ::HeapProfilerStop,
669 ::GetHeapProfile)); 672 ::GetHeapProfile));
670 #endif 673 #endif
671 } 674 }
672 675
673 int BrowserMainLoop::PreCreateThreads() { 676 int BrowserMainLoop::PreCreateThreads() {
(...skipping 732 matching lines...) Expand 10 before | Expand all | Expand 10 after
1406 DCHECK(is_tracing_startup_for_duration_); 1409 DCHECK(is_tracing_startup_for_duration_);
1407 1410
1408 is_tracing_startup_for_duration_ = false; 1411 is_tracing_startup_for_duration_ = false;
1409 TracingController::GetInstance()->DisableRecording( 1412 TracingController::GetInstance()->DisableRecording(
1410 TracingController::CreateFileSink( 1413 TracingController::CreateFileSink(
1411 startup_trace_file_, 1414 startup_trace_file_,
1412 base::Bind(OnStoppedStartupTracing, startup_trace_file_))); 1415 base::Bind(OnStoppedStartupTracing, startup_trace_file_)));
1413 } 1416 }
1414 1417
1415 } // namespace content 1418 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | sql/BUILD.gn » ('j') | sql/connection.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698