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

Unified Diff: third_party/WebKit/Source/wtf/WTF.cpp

Issue 2728453006: WTF: Initialize main-thread stack estimates when WTF starts up. (Closed)
Patch Set: fix cast for windows Created 3 years, 10 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: third_party/WebKit/Source/wtf/WTF.cpp
diff --git a/third_party/WebKit/Source/wtf/WTF.cpp b/third_party/WebKit/Source/wtf/WTF.cpp
index f6d29b5695cc606b5626c440d4990cd0d8a07532..201efc2747ad2825be7a20eb30bc19c149b53d48 100644
--- a/third_party/WebKit/Source/wtf/WTF.cpp
+++ b/third_party/WebKit/Source/wtf/WTF.cpp
@@ -32,6 +32,8 @@
#include "wtf/Assertions.h"
#include "wtf/Functional.h"
+#include "wtf/StackUtil.h"
+#include "wtf/ThreadSpecific.h"
#include "wtf/Threading.h"
#include "wtf/allocator/Partitions.h"
#include "wtf/text/AtomicString.h"
@@ -63,10 +65,13 @@ void initialize(void (*callOnMainThreadFunction)(MainThreadFunction, void*)) {
// Make that explicit here.
RELEASE_ASSERT(!s_initialized);
s_initialized = true;
+ initializeCurrentThread();
haraken 2017/03/06 01:44:03 Given that only the main thread calls this, shall
jbroman 2017/03/06 16:14:03 It only initializes the one aspect of the main thr
+ s_mainThreadIdentifier = currentThread();
+
initializeThreading();
s_callOnMainThreadFunction = callOnMainThreadFunction;
- s_mainThreadIdentifier = currentThread();
+ internal::initializeMainThreadStackEstimate();
AtomicString::init();
StringStatics::init();
}
« third_party/WebKit/Source/wtf/Threading.h ('K') | « third_party/WebKit/Source/wtf/ThreadingWin.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698