| Index: third_party/WebKit/Source/platform/heap/ThreadState.cpp
|
| diff --git a/third_party/WebKit/Source/platform/heap/ThreadState.cpp b/third_party/WebKit/Source/platform/heap/ThreadState.cpp
|
| index 63e607a711b71431ad4a61894538e1d15385ec92..8d0320d629868b43185b467f908cddaea4f1234b 100644
|
| --- a/third_party/WebKit/Source/platform/heap/ThreadState.cpp
|
| +++ b/third_party/WebKit/Source/platform/heap/ThreadState.cpp
|
| @@ -49,11 +49,8 @@
|
| #include "public/platform/WebTraceLocation.h"
|
| #include "wtf/CurrentTime.h"
|
| #include "wtf/DataLog.h"
|
| -#include "wtf/PtrUtil.h"
|
| #include "wtf/ThreadingPrimitives.h"
|
| #include "wtf/allocator/Partitions.h"
|
| -#include <memory>
|
| -#include <v8.h>
|
|
|
| #if OS(WIN)
|
| #include <stddef.h>
|
| @@ -69,6 +66,8 @@
|
| #include <pthread_np.h>
|
| #endif
|
|
|
| +#include <v8.h>
|
| +
|
| namespace blink {
|
|
|
| WTF::ThreadSpecific<ThreadState*>* ThreadState::s_threadSpecific = nullptr;
|
| @@ -78,7 +77,7 @@ uint8_t ThreadState::s_mainThreadStateStorage[sizeof(ThreadState)];
|
|
|
| ThreadState::ThreadState(bool perThreadHeapEnabled)
|
| : m_thread(currentThread())
|
| - , m_persistentRegion(wrapUnique(new PersistentRegion()))
|
| + , m_persistentRegion(adoptPtr(new PersistentRegion()))
|
| #if OS(WIN) && COMPILER(MSVC)
|
| , m_threadStackSize(0)
|
| #endif
|
| @@ -133,7 +132,7 @@ ThreadState::ThreadState(bool perThreadHeapEnabled)
|
| m_arenas[arenaIndex] = new NormalPageArena(this, arenaIndex);
|
| m_arenas[BlinkGC::LargeObjectArenaIndex] = new LargeObjectArena(this, BlinkGC::LargeObjectArenaIndex);
|
|
|
| - m_likelyToBePromptlyFreed = wrapArrayUnique(new int[likelyToBePromptlyFreedArraySize]);
|
| + m_likelyToBePromptlyFreed = adoptArrayPtr(new int[likelyToBePromptlyFreedArraySize]);
|
| clearArenaAges();
|
|
|
| // There is little use of weak references and collections off the main thread;
|
| @@ -448,7 +447,7 @@ void ThreadState::threadLocalWeakProcessing()
|
| // Due to the complexity, we just forbid allocations.
|
| NoAllocationScope noAllocationScope(this);
|
|
|
| - std::unique_ptr<Visitor> visitor = Visitor::create(this, BlinkGC::ThreadLocalWeakProcessing);
|
| + OwnPtr<Visitor> visitor = Visitor::create(this, BlinkGC::ThreadLocalWeakProcessing);
|
|
|
| // Perform thread-specific weak processing.
|
| while (popAndInvokeThreadLocalWeakCallback(visitor.get())) { }
|
| @@ -1321,7 +1320,7 @@ void ThreadState::copyStackUntilSafePointScope()
|
| }
|
| }
|
|
|
| -void ThreadState::addInterruptor(std::unique_ptr<BlinkGCInterruptor> interruptor)
|
| +void ThreadState::addInterruptor(PassOwnPtr<BlinkGCInterruptor> interruptor)
|
| {
|
| ASSERT(checkThread());
|
| SafePointScope scope(BlinkGC::HeapPointersOnStack);
|
|
|