Changeset 153357 in webkit
- Timestamp:
- Jul 25, 2013 5:13:13 PM (11 years ago)
- Location:
- trunk/Source/JavaScriptCore
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/ChangeLog
r153354 r153357 1 2013-07-25 Anders Carlsson <andersca@apple.com> 2 3 ASSERT(m_vm->apiLock().currentThreadIsHoldingLock()); fails for Safari on current ToT 4 https://bugs.webkit.org/show_bug.cgi?id=119108 5 6 Reviewed by Mark Hahnenberg. 7 8 Add a currentThreadIsHoldingAPILock() function to VM that checks if the current thread is the exclusive API thread. 9 10 * heap/CopiedSpace.cpp: 11 (JSC::CopiedSpace::tryAllocateSlowCase): 12 * heap/Heap.cpp: 13 (JSC::Heap::protect): 14 (JSC::Heap::unprotect): 15 (JSC::Heap::collect): 16 * heap/MarkedAllocator.cpp: 17 (JSC::MarkedAllocator::allocateSlowCase): 18 * runtime/JSGlobalObject.cpp: 19 (JSC::JSGlobalObject::init): 20 * runtime/VM.h: 21 (JSC::VM::currentThreadIsHoldingAPILock): 22 1 23 2013-07-25 Zan Dobersek <zdobersek@igalia.com> 2 24 -
trunk/Source/JavaScriptCore/heap/CopiedSpace.cpp
r148696 r153357 70 70 return tryAllocateOversize(bytes, outPtr); 71 71 72 ASSERT(m_heap->vm()-> apiLock().currentThreadIsHoldingLock());72 ASSERT(m_heap->vm()->currentThreadIsHoldingAPILock()); 73 73 m_heap->didAllocate(m_allocator.currentCapacity()); 74 74 -
trunk/Source/JavaScriptCore/heap/Heap.cpp
r153247 r153357 168 168 static inline bool isValidSharedInstanceThreadState(VM* vm) 169 169 { 170 return vm-> apiLock().currentThreadIsHoldingLock();170 return vm->currentThreadIsHoldingAPILock(); 171 171 } 172 172 … … 335 335 { 336 336 ASSERT(k); 337 ASSERT(m_vm-> apiLock().currentThreadIsHoldingLock());337 ASSERT(m_vm->currentThreadIsHoldingAPILock()); 338 338 339 339 if (!k.isCell()) … … 346 346 { 347 347 ASSERT(k); 348 ASSERT(m_vm-> apiLock().currentThreadIsHoldingLock());348 ASSERT(m_vm->currentThreadIsHoldingAPILock()); 349 349 350 350 if (!k.isCell()) … … 712 712 RELEASE_ASSERT(!m_deferralDepth); 713 713 GCPHASE(Collect); 714 ASSERT(vm()-> apiLock().currentThreadIsHoldingLock());714 ASSERT(vm()->currentThreadIsHoldingAPILock()); 715 715 RELEASE_ASSERT(vm()->identifierTable == wtfThreadData().currentIdentifierTable()); 716 716 ASSERT(m_isSafeToCollect); -
trunk/Source/JavaScriptCore/heap/MarkedAllocator.cpp
r153169 r153357 71 71 void* MarkedAllocator::allocateSlowCase(size_t bytes) 72 72 { 73 ASSERT(m_heap->vm()-> apiLock().currentThreadIsHoldingLock());73 ASSERT(m_heap->vm()->currentThreadIsHoldingAPILock()); 74 74 #if COLLECT_ON_EVERY_ALLOCATION 75 75 m_heap->collectAllGarbage(); -
trunk/Source/JavaScriptCore/runtime/JSGlobalObject.cpp
r153244 r153357 138 138 void JSGlobalObject::init(JSObject* thisValue) 139 139 { 140 ASSERT(vm(). apiLock().currentThreadIsHoldingLock());140 ASSERT(vm().currentThreadIsHoldingAPILock()); 141 141 142 142 setGlobalThis(vm(), thisValue); -
trunk/Source/JavaScriptCore/runtime/VM.h
r153331 r153357 469 469 } 470 470 471 bool currentThreadIsHoldingAPILock() const 472 { 473 return m_apiLock->currentThreadIsHoldingLock() || exclusiveThread == currentThread(); 474 } 475 471 476 JSLock& apiLock() { return *m_apiLock; } 472 477 CodeCache* codeCache() { return m_codeCache.get(); }
Note: See TracChangeset
for help on using the changeset viewer.