Canvas3D crashes in tracemonkey
Andrew Smith | 28 September, 2008 | 16:37I wanted to try and see if our library will work any better (or rather, how much better) wth tracemonkey instead of the current javascript engine. I got a copy of the relevant branch and built it, but that wasn’t happy with the extension, because the extension has a max version in it that’s too low.
So I installed the nightly tester tools, and overrode the version check.
Sadly the result is that irefox crashes when I go to a page with a canvas3d on it. I rebuilt firefox with debug enabled, and this is what it told me:
++DOMWINDOW == 11 (0x145be80c) [serial = 14] [outer = 0x145acfd0] WARNING: NS_ENSURE_SUCCESS(rv, rv) failed with result 0x80520012: file /Users/andrew/tracemonkey/content/base/src/nsScriptLoader.cpp, line 446 Reading symbols for shared libraries . done nsGLPbuffer: gActiveBuffers: 1 Reading symbols for shared libraries . done Reading symbols for shared libraries . done Reading symbols for shared libraries . done AGL_SAMPLE_BUFFERS_ARB 0 AGL_SAMPLES_ARB 0 AGL_MULTISAMPLE 0 AGL_SUPERSAMPLE 0 dyld: lazy symbol binding failed: Symbol not found: __ZN15gfxImageSurfaceC1ERK10gfxIntSizeN11gfxASurface14gfxImageFormatE Referenced from: /Users/andrew/Library/Application Support/Firefox/Profiles/ie0j09jy.newer/extensions/canvas3d@mozilla.com/platform/Darwin/components/libcanvas3d.dylib Expected in: /Users/andrew/tracemonkey/ff-opt/toolkit/library/XUL dyld: Symbol not found: __ZN15gfxImageSurfaceC1ERK10gfxIntSizeN11gfxASurface14gfxImageFormatE Referenced from: /Users/andrew/Library/Application Support/Firefox/Profiles/ie0j09jy.newer/extensions/canvas3d@mozilla.com/platform/Darwin/components/libcanvas3d.dylib Expected in: /Users/andrew/tracemonkey/ff-opt/toolkit/library/XUL Program received signal SIGTRAP, Trace/breakpoint trap. 0x8fe01045 in __dyld_dyld_fatal_error () (gdb) bt #0 0x8fe01045 in __dyld_dyld_fatal_error () #1 0x8fe06fa7 in __dyld__ZN4dyld14bindLazySymbolEPK11mach_headerPm () #2 0x8fe18b6f in __dyld_stub_binding_helper_interface2 () #3 0x0dbfa505 in NSGetModule () #4 0x0dc05aa4 in NSGetModule () #5 0x0dc05ea5 in NSGetModule () #6 0x0dbfb8f3 in NSGetModule () #7 0x0a97e3af in nsHTMLCanvasElement::GetContext (this=0xe907d00, aContextId=@0xbfffc898, aContext=0xbfffc8a8) at /Users/andrew/tracemonkey/content/html/content/src/nsHTMLCanvasElement.cpp:475 #8 0x0916eb4c in nsIDOMHTMLCanvasElement_GetContext (cx=0x145ad180, argc=1, vp=0xcda3d8) at dom_quickstubs.cpp:10350 #9 0x001e5ab8 in js_Interpret (cx=0x145ad180) at /Users/andrew/tracemonkey/js/src/jsinterp.cpp:4960 #10 0x001fe6b8 in js_Invoke (cx=0x145ad180, argc=1, vp=0xcda230, flags=0) at jsinterp.cpp:1324 #11 0x001fe8d9 in js_InternalInvoke (cx=0x145ad180, obj=0x144f5720, fval=230193408, flags=0, argc=1, argv=0xcda22c, rval=0xbfffcec0) at jsinterp.cpp:1381 #12 0x00198b76 in JS_CallFunctionValue (cx=0x145ad180, obj=0x8fe2fcc0, fval=-1880949568, argc=2414017728, argv=0x8fe2fcc0, rval=0x8fe2fcc0) at /Users/andrew/tracemonkey/js/src/jsapi.cpp:5071 #13 0x0ab3f8e9 in nsJSContext::CallEventHandler (this=0x145ac6a0, aTarget=0x145be80c, aScope=0x144f5720, aHandler=0xdb87900, aargv=0xe906af0, arv=0xbfffd064) at /Users/andrew/tracemonkey/dom/src/base/nsJSEnvironment.cpp:1998 #14 0x0abb8254 in nsJSEventListener::HandleEvent (this=0x10c45870, aEvent=0xe906a60) at /Users/andrew/tracemonkey/dom/src/events/nsJSEventListener.cpp:248 #15 0x0a90e65b in nsEventListenerManager::HandleEventSubType (this=0x151e6180, aListenerStruct=0x151e61a4, aListener=0x10c45870, aDOMEvent=0xe906a60, aCurrentTarget=0x145ad00c, aPhaseFlags=6) at /Users/andrew/tracemonkey/content/events/src/nsEventListenerManager.cpp:1080 #16 0x0a90f08e in nsEventListenerManager::HandleEvent (this=0x151e6180, aPresContext=0x14698890, aEvent=0xbfffd40c, aDOMEvent=0xbfffd388, aCurrentTarget=0x145ad00c, aFlags=6, aEventStatus=0xbfffd38c) at /Users/andrew/tracemonkey/content/events/src/nsEventListenerManager.cpp:1185 #17 0x0a94bd5d in nsEventTargetChainItem::HandleEvent (this=0xe07c20, aVisitor=@0xbfffd380, aFlags=6) at /Users/andrew/tracemonkey/content/events/src/nsEventDispatcher.cpp:211 #18 0x0a94c133 in nsEventTargetChainItem::HandleEventTargetChain (this=0xe07d40, aVisitor=@0xbfffd380, aFlags=6, aCallback=0x0) at /Users/andrew/tracemonkey/content/events/src/nsEventDispatcher.cpp:269 #19 0x0a94ca18 in nsEventDispatcher::Dispatch (aTarget=0x145acfd0, aPresContext=0x14698890, aEvent=0xbfffd40c, aDOMEvent=0x0, aEventStatus=0xbfffd438, aCallback=0x0) at /Users/andrew/tracemonkey/content/events/src/nsEventDispatcher.cpp:479 #20 0x0a5521bd in DocumentViewerImpl::LoadComplete (this=0xe83f160, aStatus=0) at /Users/andrew/tracemonkey/layout/base/nsDocumentViewer.cpp:985 #21 0x115ab0f1 in nsDocShell::EndPageLoad (this=0x145ac820, aProgress=0x145ac834, aChannel=0xe726600, aStatus=0) at /Users/andrew/tracemonkey/docshell/base/nsDocShell.cpp:5082 #22 0x115b7870 in nsWebShell::EndPageLoad (this=0x145ac820, aProgress=0x145ac834, channel=0xe726600, aStatus=0) at /Users/andrew/tracemonkey/docshell/base/nsWebShell.cpp:1013 #23 0x115ab953 in nsDocShell::OnStateChange (this=0x145ac820, aProgress=0x145ac834, aRequest=0xe726600, aStateFlags=131088, aStatus=0) at /Users/andrew/tracemonkey/docshell/base/nsDocShell.cpp:4987 #24 0x115cdf21 in nsDocLoader::FireOnStateChange (this=0x145ac820, aProgress=0x145ac834, aRequest=0xe726600, aStateFlags=131088, aStatus=0) at /Users/andrew/tracemonkey/uriloader/base/nsDocLoader.cpp:1235 #25 0x115ce636 in nsDocLoader::doStopDocumentLoad (this=0x145ac820, request=0xe726600, aStatus=0) at /Users/andrew/tracemonkey/uriloader/base/nsDocLoader.cpp:858 #26 0x115ce966 in nsDocLoader::DocLoaderIsEmpty (this=0xe726600) at /Users/andrew/tracemonkey/uriloader/base/nsDocLoader.cpp:763 #27 0x115cf0d4 in nsDocLoader::OnStopRequest (this=0x145ac820, aRequest=0x145d94c0, aCtxt=0x0, aStatus=0) at /Users/andrew/tracemonkey/uriloader/base/nsDocLoader.cpp:679 #28 0x0927f24f in nsLoadGroup::RemoveRequest (this=0x145acbd0, request=0x145d94c0, ctxt=0x0, aStatus=0) at /Users/andrew/tracemonkey/netwerk/base/src/nsLoadGroup.cpp:688 #29 0x0a840739 in nsDocument::DoUnblockOnload (this=0xa66600) at /Users/andrew/tracemonkey/content/base/src/nsDocument.cpp:6520 #30 0x0a848431 in nsDocument::DispatchContentLoadedEvents (this=0xa66600) at /Users/andrew/tracemonkey/content/base/src/nsDocument.cpp:3451 #31 0x0a861c9b in nsRunnableMethodLong story short, the extension uses stuff in Firefox 3 that no longer exists in current versions. I guess there’s also a possibility that the tracemonkey branch is very much out of date, but I’m having trouble believing that.::Run (this=0xe7fbf30) at nsThreadUtils.h:264 #32 0x003ef792 in nsThread::ProcessNextEvent (this=0x613d60, mayWait=0, result=0xbfffdcbc) at /Users/andrew/tracemonkey/xpcom/threads/nsThread.cpp:510 #33 0x0037c5f7 in NS_ProcessPendingEvents_P (thread=0x613d60, timeout=20) at nsThreadUtils.cpp:180 #34 0x094ea7f2 in nsBaseAppShell::NativeEventCallback (this=0x6355c0) at /Users/andrew/tracemonkey/widget/src/xpwidgets/nsBaseAppShell.cpp:121 #35 0x094ab3ea in nsAppShell::ProcessGeckoEvents (aInfo=0x6355c0) at /Users/andrew/tracemonkey/widget/src/cocoa/nsAppShell.mm:302 #36 0x90625615 in CFRunLoopRunSpecific () #37 0x90625cf8 in CFRunLoopRunInMode () #38 0x96bc2da4 in RunCurrentEventLoopInMode () #39 0x96bc2af6 in ReceiveNextEventCommon () #40 0x96bc2a31 in BlockUntilNextEventMatchingListInMode () #41 0x95ab8505 in _DPSNextEvent () #42 0x95ab7db8 in -[NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] () #43 0x95ab0df3 in -[NSApplication run] () #44 0x094aabaa in nsAppShell::Run (this=0x6355c0) at /Users/andrew/tracemonkey/widget/src/cocoa/nsAppShell.mm:591 #45 0x0a01ba0e in nsAppStartup::Run (this=0x64f310) at /Users/andrew/tracemonkey/toolkit/components/startup/src/nsAppStartup.cpp:182 #46 0x000a5104 in XRE_main (argc=1, argv=0xbffff23c, aAppData=0x60e5e0) at /Users/andrew/tracemonkey/toolkit/xre/nsAppRunner.cpp:3220 #47 0x000029ec in main (argc=1, argv=0x60baf0) at /Users/andrew/tracemonkey/browser/app/nsBrowserApp.cpp:156

Andrew, have you contacted Mozilla on the issue? Not sure
Funtomas | 29 September, 2008 | 5:56Andrew, have you contacted Mozilla on the issue? Not sure who to point at, maybe Vlad.
Was no need to contact Vlad, see next post on
Andrew Smith | 2 October, 2008 | 20:38Was no need to contact Vlad, see next post on this topic.