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

Side by Side Diff: third_party/WebKit/Source/platform/heap/ThreadState.h

Issue 1783673002: Revert of Simplify the shutdown sequence of Oilpan's heap Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after
179 using AttachedThreadStateSet = HashSet<ThreadState*>; 179 using AttachedThreadStateSet = HashSet<ThreadState*>;
180 static AttachedThreadStateSet& attachedThreads(); 180 static AttachedThreadStateSet& attachedThreads();
181 static RecursiveMutex& threadAttachMutex(); 181 static RecursiveMutex& threadAttachMutex();
182 static void lockThreadAttachMutex(); 182 static void lockThreadAttachMutex();
183 static void unlockThreadAttachMutex(); 183 static void unlockThreadAttachMutex();
184 184
185 // Initialize threading infrastructure. Should be called from the main 185 // Initialize threading infrastructure. Should be called from the main
186 // thread. 186 // thread.
187 static void init(); 187 static void init();
188 static void shutdown(); 188 static void shutdown();
189 static void shutdownHeapIfNecessary();
189 bool isTerminating() { return m_isTerminating; } 190 bool isTerminating() { return m_isTerminating; }
190 191
191 static void attachMainThread(); 192 static void attachMainThread();
192 static void detachMainThread(); 193 static void detachMainThread();
193 194
194 // Trace all persistent roots, called when marking the managed heap objects. 195 // Trace all persistent roots, called when marking the managed heap objects.
195 static void visitPersistentRoots(Visitor*); 196 static void visitPersistentRoots(Visitor*);
196 197
197 // Trace all objects found on the stack, used when doing conservative GCs. 198 // Trace all objects found on the stack, used when doing conservative GCs.
198 static void visitStackRoots(Visitor*); 199 static void visitStackRoots(Visitor*);
(...skipping 512 matching lines...) Expand 10 before | Expand all | Expand 10 after
711 712
712 template<> class ThreadStateFor<AnyThread> { 713 template<> class ThreadStateFor<AnyThread> {
713 STATIC_ONLY(ThreadStateFor); 714 STATIC_ONLY(ThreadStateFor);
714 public: 715 public:
715 static ThreadState* state() { return ThreadState::current(); } 716 static ThreadState* state() { return ThreadState::current(); }
716 }; 717 };
717 718
718 } // namespace blink 719 } // namespace blink
719 720
720 #endif // ThreadState_h 721 #endif // ThreadState_h
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/platform/heap/Heap.cpp ('k') | third_party/WebKit/Source/platform/heap/ThreadState.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698