Bug 137028

Summary: [Win64] Exceptions with CHECK_HASHTABLE_ITERATORS
Product: WebKit Reporter: Brent Fulgham <bfulgham>
Component: WebCore Misc.Assignee: Nobody <webkit-unassigned>
Status: RESOLVED DUPLICATE    
Severity: Normal CC: andersca, ap, bfulgham
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   

Description Brent Fulgham 2014-09-23 10:20:55 PDT
I'm encountering exceptions when attempting to run TestWebKitAPI under 64-bit (Debug) Windows builds. This appears to be happening when a HashTable is being destroyed, and the 'invalidateIterators' call is made.

Unhandled exception at 0x00007FF94D425BF8 in TestWebKitAPI.exe: Microsoft C++ exception: Concurrency::scheduler_resource_allocation_error at memory location 0x000000000013F788.

Call stack:

 	KernelBase.dll!RaiseException()	Unknown
 	[External Code]	
 	WebKit.dll!Concurrency::details::SchedulerBase::SchedulerBase(const Concurrency::SchedulerPolicy & policy) Line 149	C++
 	WebKit.dll!Concurrency::details::ThreadScheduler::ThreadScheduler(const Concurrency::SchedulerPolicy & policy) Line 27	C++
 	WebKit.dll!Concurrency::details::ThreadScheduler::Create(const Concurrency::SchedulerPolicy & policy) Line 34	C++
 	WebKit.dll!Concurrency::details::SchedulerBase::CreateWithoutInitializing(const Concurrency::SchedulerPolicy & policy) Line 285	C++
 	WebKit.dll!Concurrency::details::SchedulerBase::GetDefaultScheduler() Line 654	C++
 	WebKit.dll!Concurrency::details::SchedulerBase::CreateContextFromDefaultScheduler() Line 573	C++
 	WebKit.dll!Concurrency::details::LockQueueNode::LockQueueNode(unsigned int timeout) Line 619	C++
 	WebKit.dll!Concurrency::critical_section::lock() Line 1031	C++
 	WebKit.dll!mtx_do_lock(_Mtx_internal_imp_t * * mtx, const xtime * target) Line 67	C++
 	WebKit.dll!std::_Mtx_lockX(_Mtx_internal_imp_t * * _Mtx) Line 68	C++
 	WebKit.dll!std::_Mutex_base::lock() Line 42	C++
 	WebKit.dll!std::lock_guard<std::mutex>::lock_guard<std::mutex>(std::mutex & _Mtx) Line 184	C++
>	WebKit.dll!WTF::HashTable<WebCore::ProtectionSpace,WTF::KeyValuePair<WebCore::ProtectionSpace,WebCore::Credential>,WTF::KeyValuePairKeyExtractor<WTF::KeyValuePair<WebCore::ProtectionSpace,WebCore::Credential> >,WebCore::ProtectionSpaceHash,WTF::HashMap<WebCore::ProtectionSpace,WebCore::Credential,WebCore::ProtectionSpaceHash,WTF::HashTraits<WebCore::ProtectionSpace>,WTF::HashTraits<WebCore::Credential> >::KeyValuePairTraits,WTF::HashTraits<WebCore::ProtectionSpace> >::invalidateIterators() Line 1292	C++
 	WebKit.dll!WTF::HashTable<WTF::ListHashSetNode<WebCore::RenderBox * __ptr64,16> * __ptr64,WTF::ListHashSetNode<WebCore::RenderBox * __ptr64,16> * __ptr64,WTF::IdentityExtractor,WTF::ListHashSetNodeHashFunctions<WTF::PtrHash<WebCore::RenderBox * __ptr64> >,WTF::HashTraits<WTF::ListHashSetNode<WebCore::RenderBox * __ptr64,16> * __ptr64>,WTF::HashTraits<WTF::ListHashSetNode<WebCore::RenderBox * __ptr64,16> * __ptr64> >::~HashTable<WTF::ListHashSetNode<WebCore::RenderBox * __ptr64,16> * __ptr64,WTF::ListHashSetNode<WebCore::RenderBox * __ptr64,16> * __ptr64,WTF::IdentityExtractor,WTF::ListHashSetNodeHashFunctions<WTF::PtrHash<WebCore::RenderBox * __ptr64> >,WTF::HashTraits<WTF::ListHashSetNode<WebCore::RenderBox * __ptr64,16> * __ptr64>,WTF::HashTraits<WTF::ListHashSetNode<WebCore::RenderBox * __ptr64,16> * __ptr64> >() Line 352	C++
 	[External Code]	

The TestWebKitAPI program has proceeded as follows:

WebCoreLayoutUnit.
  LayoutUnitInt
  LayoutUnitFloat
  LayoutUnitRounding
  LayoutUnitMultiplication
  LayoutUnitDivision
  LayoutUnitCeil
  LayoutUnitFloor
WebViewDestruction.
  NoInitWithFrame
  CloseWithoutInitWithFrame
WebViewDestructionWithHostWindow.
  CloseWithoutDestroyViewWindow
  DestroyViewWindowWithoutClose
  CloseThenDestroyViewWindow
  DestroyViewWindowThenClose
  DestroyHostWindow
  DestroyHostWindowThenClose
  CloseThenDestroyHostWindow
RetainPtr.
  AdoptCF
RetainPtrHashing.
  HashSet
  HashMapKey
  HashMapValue
WTF.
  Checked_int8_t
  Checked_int16_t
  Checked_int32_t
  Checked_uint32_t
  Checked_int64_t
  Checked_uint64_t
  Lrint
  clampToIntLong
  clampToIntLongLong
  clampToIntegerFloat
  clampToIntegerDouble
  clampToFloat
  clampToUnsignedLong
  clampToUnsignedLongLong
  MediaTime
  SaturatedArithmeticAddition
  SaturatedArithmeticSubtraction
  StringHasher
  StringHasher_addCharacter
  StringHasher_addCharacters
  StringHasher_addCharactersAssumingAligned
  StringHasher_computeHash
  StringHasher_computeHashAndMaskTop8Bits
  StringHasher_hashMemory
  StringOperators
FunctionalTest.
  Basic
  UnaryBind
  BinaryBind
  MemberFunctionBind
  MemberFunctionBindRefDeref
  RefCountedStorage
WTF_HashMap.
  HashTableIteratorComparison
  DoubleHashCollisions
  MoveOnlyValues
  MoveOnlyKeys
  InitializerList
  EfficientGetter
  OwnPtrKey
  OwnPtrKey_FindUsingRawPointer
  OwnPtrKey_ContainsUsingRawPointer
  OwnPtrKey_GetUsingRawPointer
  OwnPtrKey_RemoveUsingRawPointer
  OwnPtrKey_TakeUsingRawPointer
  UniquePtrKey
  UniquePtrKey_CustomDeleter
  UniquePtrKey_FindUsingRawPointer
  UniquePtrKey_ContainsUsingRawPointer
  UniquePtrKey_GetUsingRawPointer
  UniquePtrKey_RemoveUsingRawPointer
  UniquePtrKey_TakeUsingRawPointer
WTF_MD5.
  Computation
WTF_Ref.
  Basic
  Assignment
  ReturnValue
WTF_RefPtr.
  Basic
  AssignPassRefToRefPtr
  Adopt
  Assignment
  Swap
  ReleaseNonNull
  Release
  ReturnValue
WTF_SHA1.
  Computation
WTF_Vector.
  Basic
  Iterator
  OverloadedOperatorAmpersand
  AppendLast
  InitializerList
  Reverse
  ReverseIterator
  MoveOnly_UncheckedAppend
  MoveOnly_Append
  MoveOnly_Insert
  MoveOnly_TakeLast
  VectorOfVectorsOfVectorsInlineCapacitySwap
Comment 1 Brent Fulgham 2014-09-24 10:27:14 PDT
This exception seems to be happening after the tests complete, during program shutdown (i.e., at the point where the program is returning from 'main'.

From the signature of the HashTable, it looks like this is a ListHashSet object.

A cursory scan through the sources doesn't reveal any likely ListHashSet global objects that might be the cause.
Comment 2 Brent Fulgham 2014-09-24 14:46:54 PDT

*** This bug has been marked as a duplicate of bug 133553 ***