ASSERT(m_vm->apiLock().currentThreadIsHoldingLock()); fails for Safari on current ToT
authorandersca@apple.com <andersca@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 26 Jul 2013 00:13:13 +0000 (00:13 +0000)
committerandersca@apple.com <andersca@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 26 Jul 2013 00:13:13 +0000 (00:13 +0000)
commit9354f1305f905064e2aeb3c61ce9721b9b92b6eb
treeaf758eefc3075e27204bba6af7703a9e9630416b
parent7084b079acfeee2cb6f2c6cbfcfff07c67c61704
ASSERT(m_vm->apiLock().currentThreadIsHoldingLock()); fails for Safari on current ToT
https://bugs.webkit.org/show_bug.cgi?id=119108

Reviewed by Mark Hahnenberg.

Add a currentThreadIsHoldingAPILock() function to VM that checks if the current thread is the exclusive API thread.

* heap/CopiedSpace.cpp:
(JSC::CopiedSpace::tryAllocateSlowCase):
* heap/Heap.cpp:
(JSC::Heap::protect):
(JSC::Heap::unprotect):
(JSC::Heap::collect):
* heap/MarkedAllocator.cpp:
(JSC::MarkedAllocator::allocateSlowCase):
* runtime/JSGlobalObject.cpp:
(JSC::JSGlobalObject::init):
* runtime/VM.h:
(JSC::VM::currentThreadIsHoldingAPILock):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@153357 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/JavaScriptCore/ChangeLog
Source/JavaScriptCore/heap/CopiedSpace.cpp
Source/JavaScriptCore/heap/Heap.cpp
Source/JavaScriptCore/heap/MarkedAllocator.cpp
Source/JavaScriptCore/runtime/JSGlobalObject.cpp
Source/JavaScriptCore/runtime/VM.h