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

Unified Diff: third_party/WebKit/Source/bindings/core/v8/WindowProxy.cpp

Issue 2003293003: [Binding] [UMA] Add a UMA to track time spent in WindowProxy::initialize (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/bindings/core/v8/WindowProxy.cpp
diff --git a/third_party/WebKit/Source/bindings/core/v8/WindowProxy.cpp b/third_party/WebKit/Source/bindings/core/v8/WindowProxy.cpp
index 7b6d9481037862a9ae2daf4096626ba8ec1464c3..d91a9dae7b335ca963241c53f85495a56d1af6f1 100644
--- a/third_party/WebKit/Source/bindings/core/v8/WindowProxy.cpp
+++ b/third_party/WebKit/Source/bindings/core/v8/WindowProxy.cpp
@@ -61,6 +61,7 @@
#include "platform/weborigin/SecurityOrigin.h"
#include "public/platform/Platform.h"
#include "wtf/Assertions.h"
+#include "wtf/CurrentTime.h"
#include "wtf/OwnPtr.h"
#include "wtf/StringExtras.h"
#include "wtf/text/CString.h"
@@ -225,6 +226,7 @@ bool WindowProxy::initialize()
{
TRACE_EVENT0("v8", "WindowProxy::initialize");
TRACE_EVENT_SCOPED_SAMPLING_STATE("blink", "InitializeWindow");
+ double startTime = currentTimeMS();
kouhei (in TOK) 2016/05/24 09:08:12 use monotonicallyIncreasingTime() instead of curre
peria 2016/05/24 09:36:24 Oh, I misunderstood the last argument of CustomCou
ScriptForbiddenScope::AllowUserAgentScript allowScript;
@@ -269,6 +271,10 @@ bool WindowProxy::initialize()
MainThreadDebugger::instance()->contextCreated(m_scriptState.get(), frame, origin);
frame->loader().client()->didCreateScriptContext(context, m_world->extensionGroup(), m_world->worldId());
}
+
+ double endTime = currentTimeMS();
+ DEFINE_STATIC_LOCAL(CustomCountHistogram, initializeHistogram, ("Blink.Binding.InitializeWindowProxy", 0, 200, 5));
+ initializeHistogram.count(endTime - startTime);
return true;
}
« no previous file with comments | « no previous file | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698