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

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

Issue 661603005: Oilpan: Introduce class MainThreadOnly (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 2 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 | « Source/platform/heap/Handle.h ('k') | Source/platform/heap/Heap.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/platform/heap/Heap.h
diff --git a/Source/platform/heap/Heap.h b/Source/platform/heap/Heap.h
index aaa91892dcebc1b96df3b475168c9c0a5cf7998f..c5d4225baf21da1ce19914d151d3085d8b18f0bf 100644
--- a/Source/platform/heap/Heap.h
+++ b/Source/platform/heap/Heap.h
@@ -1550,14 +1550,14 @@ public:
static void enterNoAllocationScope()
{
#if ENABLE(ASSERT)
- ThreadStateFor<AnyThread>::state()->enterNoAllocationScope();
+ ThreadStateFor<AnyThreadAffinity>::state()->enterNoAllocationScope();
#endif
}
static void leaveNoAllocationScope()
{
#if ENABLE(ASSERT)
- ThreadStateFor<AnyThread>::state()->leaveNoAllocationScope();
+ ThreadStateFor<AnyThreadAffinity>::state()->leaveNoAllocationScope();
#endif
}
@@ -1761,15 +1761,15 @@ struct ThreadingTrait<WeakMember<T> > {
template<typename Key, typename Value, typename T, typename U, typename V>
struct ThreadingTrait<HashMap<Key, Value, T, U, V, HeapAllocator> > {
static const ThreadAffinity Affinity =
- (ThreadingTrait<Key>::Affinity == MainThreadOnly)
- && (ThreadingTrait<Value>::Affinity == MainThreadOnly) ? MainThreadOnly : AnyThread;
+ (ThreadingTrait<Key>::Affinity == MainThreadAffinity)
+ && (ThreadingTrait<Value>::Affinity == MainThreadAffinity) ? MainThreadAffinity : AnyThreadAffinity;
};
template<typename First, typename Second>
struct ThreadingTrait<WTF::KeyValuePair<First, Second> > {
static const ThreadAffinity Affinity =
- (ThreadingTrait<First>::Affinity == MainThreadOnly)
- && (ThreadingTrait<Second>::Affinity == MainThreadOnly) ? MainThreadOnly : AnyThread;
+ (ThreadingTrait<First>::Affinity == MainThreadAffinity)
+ && (ThreadingTrait<Second>::Affinity == MainThreadAffinity) ? MainThreadAffinity : AnyThreadAffinity;
};
template<typename T, typename U, typename V>
@@ -1803,8 +1803,8 @@ struct ThreadingTrait<HeapHashTableBacking<Table> > {
typedef typename Table::KeyType Key;
typedef typename Table::ValueType Value;
static const ThreadAffinity Affinity =
- (ThreadingTrait<Key>::Affinity == MainThreadOnly)
- && (ThreadingTrait<Value>::Affinity == MainThreadOnly) ? MainThreadOnly : AnyThread;
+ (ThreadingTrait<Key>::Affinity == MainThreadAffinity)
+ && (ThreadingTrait<Value>::Affinity == MainThreadAffinity) ? MainThreadAffinity : AnyThreadAffinity;
};
template<typename T, typename U, typename V, typename W, typename X>
« no previous file with comments | « Source/platform/heap/Handle.h ('k') | Source/platform/heap/Heap.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698