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

Unified Diff: shell/context.cc

Issue 1024723002: Add some trace points to mojo_shell for app lifetime (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 9 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
Index: shell/context.cc
diff --git a/shell/context.cc b/shell/context.cc
index 91bfa120ce7da5c237221695044250455e6f840d..35485ba21b83c1308127586fee4a247dc4a4c7aa 100644
--- a/shell/context.cc
+++ b/shell/context.cc
@@ -18,6 +18,7 @@
#include "base/run_loop.h"
#include "base/strings/string_split.h"
#include "base/strings/string_util.h"
+#include "base/trace_event/trace_event.h"
#include "build/build_config.h"
#include "mojo/common/trace_controller_impl.h"
#include "mojo/common/tracing_impl.h"
@@ -234,6 +235,7 @@ GURL Context::ResolveCommandLineURL(const std::string& path) {
}
bool Context::Init() {
+ TRACE_EVENT0("mojo_shell", "Context::Init");
const base::CommandLine& command_line =
*base::CommandLine::ForCurrentProcess();
@@ -298,6 +300,7 @@ bool Context::Init() {
}
void Context::Shutdown() {
+ TRACE_EVENT0("mojo_shell", "Context::Shutdown");
DCHECK_EQ(base::MessageLoop::current()->task_runner(),
task_runners_->shell_runner());
embedder::ShutdownIPCSupport();
@@ -306,6 +309,7 @@ void Context::Shutdown() {
}
void Context::OnApplicationError(const GURL& url) {
+ TRACE_EVENT1("mojo_shell", "Context::OnApplicationError", "url", url.spec());
if (app_urls_.find(url) != app_urls_.end()) {
app_urls_.erase(url);
if (app_urls_.empty() && base::MessageLoop::current()->is_running()) {
« shell/application_manager/network_fetcher.cc ('K') | « shell/application_manager/network_fetcher.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698