Closed Bug 1041695 Opened 5 years ago Closed 5 years ago

[e10s] ABORT: not on worker thread! when mozilla::VideoChunk attempts to free a D3D9SurfaceImage from the wrong thread


(Core :: Graphics, defect)

Windows 7
Not set



Tracking Status
e10s + ---


(Reporter: jimm, Assigned: handyman)




(1 file, 1 obsolete file)

mach mochitest-plain content/media/test/test_streams_element_capture.html --e10s

xul.dll!RealBreak() Line 504	C++
xul.dll!NS_DebugBreak(unsigned int aSeverity=3, const char * aStr=0x1393ee5c, const char * aExpr=0x1393ee78, const char * aFile=0x1393eeb0, int aLine=362) Line 427	C++
xul.dll!mozilla::ipc::MessageChannel::AssertWorkerThread() Line 361	C++
>	xul.dll!mozilla::ipc::MessageChannel::CxxStackFrame::CxxStackFrame(mozilla::ipc::MessageChannel & that={...}, mozilla::ipc::Direction direction=OUT_MESSAGE, const IPC::Message * msg=0x067a50b0) Line 146	C++
xul.dll!mozilla::ipc::MessageChannel::Send(IPC::Message * aMsg=0x067a50b0) Line 413	C++
xul.dll!mozilla::layers::PTextureChild::SendRemoveTexture() Line 115	C++
xul.dll!mozilla::layers::TextureClient::ForceRemove() Line 436	C++
xul.dll!mozilla::layers::ShadowLayerForwarder::RemoveTexture(mozilla::layers::TextureClient * aTexture=0x08911880) Line 460	C++
xul.dll!mozilla::layers::TextureClient::Finalize() Line 479	C++
xul.dll!mozilla::AtomicRefCountedWithFinalize<mozilla::layers::TextureClient>::Release() Line 61	C++
xul.dll!mozilla::RefPtr<mozilla::layers::TextureClient>::unref(mozilla::layers::TextureClient * aVal=0x08911880) Line 303	C++
xul.dll!mozilla::RefPtr<mozilla::layers::TextureClient>::~RefPtr<mozilla::layers::TextureClient>() Line 242	C++
xul.dll!mozilla::layers::D3D9SurfaceImage::~D3D9SurfaceImage() Line 20	C++
xul.dll!mozilla::layers::D3D9SurfaceImage::`scalar deleting destructor'(unsigned int)	C++
xul.dll!mozilla::layers::Image::Release() Line 144	C++
xul.dll!nsRefPtr<mozilla::layers::Image>::~nsRefPtr<mozilla::layers::Image>() Line 854	C++
xul.dll!mozilla::VideoFrame::~VideoFrame() Line 25	C++
xul.dll!mozilla::VideoChunk::~VideoChunk() Line 45	C++
xul.dll!mozilla::VideoChunk::`scalar deleting destructor'(unsigned int)	C++
xul.dll!nsTArrayElementTraits<mozilla::VideoChunk>::Destruct(mozilla::VideoChunk * aE=0x067d4438) Line 481	C++
xul.dll!nsTArray_Impl<mozilla::VideoChunk,nsTArrayInfallibleAllocator>::DestructRange(unsigned int aStart=1, unsigned int aCount=2) Line 1611	C++
xul.dll!nsTArray_Impl<mozilla::VideoChunk,nsTArrayInfallibleAllocator>::RemoveElementsAt(unsigned int aStart=1, unsigned int aCount=2) Line 1309	C++
xul.dll!mozilla::MediaSegmentBase<mozilla::VideoSegment,mozilla::VideoChunk>::RemoveLeading(__int64 aDuration=59841, unsigned int aStartIndex=1) Line 350	C++
xul.dll!mozilla::MediaSegmentBase<mozilla::VideoSegment,mozilla::VideoChunk>::ForgetUpTo(__int64 aDuration=119387) Line 170	C++
xul.dll!mozilla::StreamBuffer::Track::ForgetUpTo(__int64 aTime=119387) Line 155	C++
xul.dll!mozilla::StreamBuffer::ForgetUpTo(__int64 aTime=5265) Line 101	C++
xul.dll!mozilla::MediaStream::AdvanceTimeVaryingValuesToCurrentTime(__int64 aCurrentTime=688913, __int64 aBlockedTime=0) Line 568	C++
xul.dll!mozilla::MediaStreamGraphImpl::UpdateCurrentTime() Line 421	C++
xul.dll!mozilla::MediaStreamGraphImpl::RunThread() Line 1272	C++
xul.dll!mozilla::`anonymous namespace'::MediaStreamGraphInitThreadRunnable::Run() Line 1497	C++
xul.dll!nsThread::ProcessNextEvent(bool aMayWait=false, bool * aResult=0x091afa5b) Line 766	C++
xul.dll!NS_ProcessNextEvent(nsIThread * aThread=0x06a45280, bool aMayWait=false) Line 265	C++
xul.dll!mozilla::ipc::MessagePumpForNonMainThreads::Run(base::MessagePump::Delegate * aDelegate=0x03965400) Line 326	C++
xul.dll!MessageLoop::RunInternal() Line 230	C++
xul.dll!MessageLoop::RunHandler() Line 223	C++
xul.dll!MessageLoop::Run() Line 197	C++
xul.dll!nsThread::ThreadFunc(void * aArg=0x06a45280) Line 353	C++
nss3.dll!_PR_NativeRunThread(void * arg=0x03911de0) Line 397	C
nss3.dll!pr_root(void * arg=0x03911de0) Line 90	C
msvcr100.dll!_callthreadstartex() Line 314	C
msvcr100.dll!_threadstartex(void * ptd=0x00327080) Line 292	C
kernel32.dll!75d1338a()	Unknown
ntdll.dll!___RtlUserThreadStart@8()	Unknown
ntdll.dll!__RtlUserThreadStart@8()	Unknown
Summary: [e10s] ABORT: not on worker thread! when mozilla::VideoChunk attempts to free a D3D9SurfaceImage from a the wrong thread → [e10s] ABORT: not on worker thread! when mozilla::VideoChunk attempts to free a D3D9SurfaceImage from the wrong thread
Dave, any chance you might be able to help out here? This looks kind of ugly, like the video src doesn't expect any ipc traffic when releasing resources.
Flags: needinfo?(davidp99)
Assignee: nobody → davidp99
Flags: needinfo?(davidp99)
Comment on attachment 8466504 [details] [diff] [review]
Run ShadowLayersForwarder::ReleaseTexture on worker thread

Requesting Bas review (or reassign to a more appropriate reviewer).
Attachment #8466504 - Flags: review?(bas)
Comment on attachment 8466504 [details] [diff] [review]
Run ShadowLayersForwarder::ReleaseTexture on worker thread

Review of attachment 8466504 [details] [diff] [review]:

Does this make sense to you Nical?
Attachment #8466504 - Flags: review?(bas) → review?(nical.bugzilla)
Comment on attachment 8466504 [details] [diff] [review]
Run ShadowLayersForwarder::ReleaseTexture on worker thread

Review of attachment 8466504 [details] [diff] [review]:

Cool, this matches what ImageBridge does, and I wasn't found of ImageBridge and ShadowLayerForwarder not having the same requirements regarding texture deallocation
Attachment #8466504 - Flags: review?(nical.bugzilla) → review+
Try push is in comment 3
Closed: 5 years ago
Keywords: checkin-needed
Resolution: --- → FIXED
Did you intend to mark this as fixed? (Looks like the patch hasn't landed yet.)
Resolution: FIXED → ---
Thanks Jim.  I believe I meant 'assigned'...
I had to back this out in for build bustage:

Can you push this to try again, but have it do debug builds and tests as well? The two failures so far have both been on debug linux builds, so it might be a debug-only thing.
Flags: needinfo?(davidp99)
I'm on it...
Flags: needinfo?(davidp99)
Added a missing #include for Linux Debug.

Try build:

(Results are currently coming in but previous Linux Debug failures are already showing as green so I'm giving it another go.)
Attachment #8466504 - Attachment is obsolete: true
Keywords: checkin-needed
Closed: 5 years ago5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla34
Blocks: 1065881
You need to log in before you can comment on or make changes to this bug.