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

Unified Diff: Source/platform/heap/ThreadState.h

Issue 794223003: Cheaper thread-safe atomic initialization of static references. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Add type check for initial value Created 5 years, 11 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: Source/platform/heap/ThreadState.h
diff --git a/Source/platform/heap/ThreadState.h b/Source/platform/heap/ThreadState.h
index e7775ea86c871b0e7e511134abb3d78b3a41fc09..c94e4b68d885d3f960573290a905b3df38ead42b 100644
--- a/Source/platform/heap/ThreadState.h
+++ b/Source/platform/heap/ThreadState.h
@@ -473,7 +473,7 @@ public:
// List of global persistent roots not owned by any particular thread.
// globalRootsMutex must be acquired before any modifications.
- static PersistentNode* globalRoots();
+ static PersistentNode& globalRoots();
static Mutex& globalRootsMutex();
// Visit local thread stack and trace all pointers conservatively.

Powered by Google App Engine
This is Rietveld 408576698