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

Side by Side Diff: Source/heap/ThreadState.h

Issue 100433005: [oilpan] Rename PauseScope to SafePointScope (Closed) Base URL: svn://svn.chromium.org/blink/branches/oilpan
Patch Set: Created 7 years 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 | Annotate | Revision Log
« no previous file with comments | « Source/core/workers/WorkerThread.cpp ('k') | Source/modules/webdatabase/DatabaseThread.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 216 matching lines...) Expand 10 before | Expand all | Expand 10 after
227 227
228 static ThreadState* Current(); 228 static ThreadState* Current();
229 static ThreadState* MainThreadState() { return &s_mainThreadState; } 229 static ThreadState* MainThreadState() { return &s_mainThreadState; }
230 static bool IsMainThread() { return Current() == MainThreadState(); } 230 static bool IsMainThread() { return Current() == MainThreadState(); }
231 231
232 static void stopThreads(StackState); 232 static void stopThreads(StackState);
233 static void resumeThreads(); 233 static void resumeThreads();
234 234
235 void safePoint(); 235 void safePoint();
236 236
237 class PauseScope { 237 class SafePointScope {
238 public: 238 public:
239 PauseScope(StackState stackState) { ThreadState::Current()->paused(stack State); } 239 SafePointScope(StackState stackState) { ThreadState::Current()->paused(s tackState); }
Mads Ager (chromium) 2013/12/05 08:39:42 As discussed offline we should change the names of
240 ~PauseScope() { ThreadState::Current()->resumed(); } 240 ~SafePointScope() { ThreadState::Current()->resumed(); }
241 }; 241 };
242 242
243 void visitStack(Visitor*); 243 void visitStack(Visitor*);
244 void visitPersistents(Visitor*); 244 void visitPersistents(Visitor*);
245 bool checkAndVisitPointer(Visitor*, Address); 245 bool checkAndVisitPointer(Visitor*, Address);
246 bool isConsistentForGC(); 246 bool isConsistentForGC();
247 void makeConsistentForGC(); 247 void makeConsistentForGC();
248 void getStats(HeapStats&); 248 void getStats(HeapStats&);
249 HeapStats& stats() { return m_stats; } 249 HeapStats& stats() { return m_stats; }
250 HeapStats& statsAfterLastGC() { return m_statsAfterLastGC; } 250 HeapStats& statsAfterLastGC() { return m_statsAfterLastGC; }
(...skipping 142 matching lines...) Expand 10 before | Expand all | Expand 10 after
393 REQUIRE_THREADSAFE_HANDLES_WITH_NAMESPACE(WTF, Int32Array); 393 REQUIRE_THREADSAFE_HANDLES_WITH_NAMESPACE(WTF, Int32Array);
394 REQUIRE_THREADSAFE_HANDLES_WITH_NAMESPACE(WTF, Uint32Array); 394 REQUIRE_THREADSAFE_HANDLES_WITH_NAMESPACE(WTF, Uint32Array);
395 REQUIRE_THREADSAFE_HANDLES_WITH_NAMESPACE(WTF, Float32Array); 395 REQUIRE_THREADSAFE_HANDLES_WITH_NAMESPACE(WTF, Float32Array);
396 REQUIRE_THREADSAFE_HANDLES_WITH_NAMESPACE(WTF, Float64Array); 396 REQUIRE_THREADSAFE_HANDLES_WITH_NAMESPACE(WTF, Float64Array);
397 REQUIRE_THREADSAFE_HANDLES_WITH_NAMESPACE(WebKit, IDBCallbacksProxy); 397 REQUIRE_THREADSAFE_HANDLES_WITH_NAMESPACE(WebKit, IDBCallbacksProxy);
398 REQUIRE_THREADSAFE_HANDLES_WITH_NAMESPACE(WebKit, IDBDatabaseBackendProxy); 398 REQUIRE_THREADSAFE_HANDLES_WITH_NAMESPACE(WebKit, IDBDatabaseBackendProxy);
399 REQUIRE_THREADSAFE_HANDLES_WITH_NAMESPACE(WebKit, IDBDatabaseCallbacksProxy); 399 REQUIRE_THREADSAFE_HANDLES_WITH_NAMESPACE(WebKit, IDBDatabaseCallbacksProxy);
400 REQUIRE_THREADSAFE_HANDLES_WITH_NAMESPACE(WebKit, IDBFactoryBackendProxy); 400 REQUIRE_THREADSAFE_HANDLES_WITH_NAMESPACE(WebKit, IDBFactoryBackendProxy);
401 401
402 #endif 402 #endif
OLDNEW
« no previous file with comments | « Source/core/workers/WorkerThread.cpp ('k') | Source/modules/webdatabase/DatabaseThread.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698