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

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

Issue 874003002: Oilpan: dispose ServiceWorker (and registration) objects earlier. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: 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 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 143 matching lines...) Expand 10 before | Expand all | Expand 10 after
154 static bool invokePreFinalizer(void* object, Visitor& visitor) \ 154 static bool invokePreFinalizer(void* object, Visitor& visitor) \
155 { \ 155 { \
156 Class* self = reinterpret_cast<Class*>(object); \ 156 Class* self = reinterpret_cast<Class*>(object); \
157 if (visitor.isAlive(self)) \ 157 if (visitor.isAlive(self)) \
158 return false; \ 158 return false; \
159 self->method(); \ 159 self->method(); \
160 return true; \ 160 return true; \
161 } \ 161 } \
162 using UsingPreFinazlizerMacroNeedsTrailingSemiColon = char 162 using UsingPreFinazlizerMacroNeedsTrailingSemiColon = char
163 163
164 #if ENABLE(OILPAN)
165 #define WILL_BE_USING_PRE_FINALIZER(Class, method) USING_PRE_FINALIZER(Class, me thod)
166 #define WILL_REGISTER_PREFINALIZER(objectPointer) ThreadState::current()->regist erPreFinalizer(*objectPointer)
167 #define WILL_UNREGISTER_PREFINALIZER(objectPointer) ThreadState::current()->unre gisterPreFinalizer(*objectPointer)
haraken 2015/01/26 01:39:42 I'm not quite sure how helpful these macros are th
sof 2015/01/26 10:06:57 ok, i'm fine with waiting until a later juncture w
168 #else
169 #define WILL_BE_USING_PRE_FINALIZER(Class, method)
170 #define WILL_REGISTER_PREFINALIZER(objectPointer)
171 #define WILL_UNREGISTER_PREFINALIZER(objectPointer)
172 #endif
173
164 // List of typed heaps. The list is used to generate the implementation 174 // List of typed heaps. The list is used to generate the implementation
165 // of typed heap related methods. 175 // of typed heap related methods.
166 // 176 //
167 // To create a new typed heap add a H(<ClassName>) to the 177 // To create a new typed heap add a H(<ClassName>) to the
168 // FOR_EACH_TYPED_HEAP macro below. 178 // FOR_EACH_TYPED_HEAP macro below.
169 #define FOR_EACH_TYPED_HEAP(H) \ 179 #define FOR_EACH_TYPED_HEAP(H) \
170 H(Node) \ 180 H(Node) \
171 H(RenderObject) \ 181 H(RenderObject) \
172 H(CSSValue) 182 H(CSSValue)
173 183
(...skipping 545 matching lines...) Expand 10 before | Expand all | Expand 10 after
719 m_locked = false; 729 m_locked = false;
720 } 730 }
721 731
722 MutexBase& m_mutex; 732 MutexBase& m_mutex;
723 bool m_locked; 733 bool m_locked;
724 }; 734 };
725 735
726 } // namespace blink 736 } // namespace blink
727 737
728 #endif // ThreadState_h 738 #endif // ThreadState_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698