Closed Bug 1528396 Opened 1 year ago Closed 1 year ago

GL symbol loading must be more precise before we can load multiple libraries at once

Categories

(Core :: Graphics, enhancement, P1)

enhancement

Tracking

()

RESOLVED FIXED
mozilla67
Tracking Status
firefox67 --- fixed

People

(Reporter: jgilbert, Assigned: jgilbert)

References

(Blocks 2 open bugs)

Details

(Whiteboard: gfx-noted)

Attachments

(1 file)

One of the symbol loading fallbacks is "find me any symbol with this name that has been loaded in any library". This isn't safe once we load multiple GL libraries.

Blocks: 1528398

In particular, don't fallback to loading symbols from any loaded
library.

Pushed by jgilbert@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/e74b9560a9d4
More precise GL symbol loading. r=lsalzman

Backed out changeset e74b9560a9d4 (Bug 1528396) for causing mochitest webgl failures on test_pixel_pack_buffer.

Push with failures: https://treeherder.mozilla.org/#/jobs?repo=autoland&group_state=expanded&searchStr=windows%2C7%2Cdebug%2Cmochitests%2Cwith%2Ce10s%2Ctest-windows7-32%2Fdebug-mochitest-webgl1-core-e10s%2Cm-e10s%28gl1c%29&fromchange=5fafa838de111e11253c041ecf98e56f782beac4&tochange=ddbb01dd4359e392a1193bce3f128630f3829f84&selectedJob=229524466

Failure log: https://treeherder.mozilla.org/logviewer.html#/jobs?job_id=229524466&repo=autoland&lineNumber=13775

Backout link: https://hg.mozilla.org/integration/autoland/rev/ddbb01dd4359e392a1193bce3f128630f3829f84

02:31:37 INFO - TEST-START | dom/canvas/test/webgl-mochitest/test_pixel_pack_buffer.html
02:31:38 INFO - GECKO(1436) | ++DOMWINDOW == 46 (0DC6D800) [pid = 4216] [serial = 86] [outer = 014FD7A0]
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glBlendFunc'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glClear'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glClearColor'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glClearStencil'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glColorMask'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glCullFace'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glDepthFunc'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glDepthMask'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glDisable'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glEnable'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glFinish'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glFlush'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glFrontFace'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glGetIntegerv'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glGetFloatv'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glGetBooleanv'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glGetError'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glTexParameteri'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glTexParameteriv'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glTexParameterf'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glGetString'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glGetTexParameterfv'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glGetTexParameteriv'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glHint'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glIsEnabled'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glLineWidth'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glPixelStorei'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glReadPixels'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glScissor'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glStencilFunc'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glStencilMask'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glStencilOp'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glTexImage2D'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glViewport'.
02:31:38 INFO - GECKO(1436) | [Child 4216, Main Thread] ###!!! ASSERTION: Failed to load symbols for GL.: 'Error', file z:/build/build/src/gfx/gl/GLContext.cpp, line 332
02:32:22 INFO - GECKO(1436) | #01: mozilla::gl::GLContext::Init() [gfx/gl/GLContext.cpp:311]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #02: mozilla::gl::GLContextProviderWGL::CreateHeadless(mozilla::gl::CreateContextFlags,nsTSubstring<char> * const) [gfx/gl/GLContextProviderWGL.cpp:526]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #03: mozilla::gl::GLContextProviderWGL::CreateOffscreen(mozilla::gfx::IntSizeTyped<mozilla::gfx::UnknownUnits> const &,mozilla::gl::SurfaceCaps const &,mozilla::gl::CreateContextFlags,nsTSubstring<char> * const) [gfx/gl/GLContextProviderWGL.cpp:536]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #04: mozilla::WebGLContext::CreateAndInitGL(bool,std::vector<mozilla::WebGLContext::FailureReason,std::allocator<mozilla::WebGLContext::FailureReason> > * const) [dom/canvas/WebGLContext.cpp:590]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #05: mozilla::WebGLContext::SetDimensions(int,int) [dom/canvas/WebGLContext.cpp:843]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #06: mozilla::dom::CanvasRenderingContextHelper::UpdateContext(JSContext *,JS::Handle<JS::Value>,mozilla::ErrorResult &) [dom/canvas/CanvasRenderingContextHelper.cpp:214]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #07: mozilla::dom::CanvasRenderingContextHelper::GetContext(JSContext *,nsTSubstring<char16_t> const &,JS::Handle<JS::Value>,mozilla::ErrorResult &) [dom/canvas/CanvasRenderingContextHelper.cpp:173]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #08: mozilla::dom::HTMLCanvasElement::GetContext(JSContext *,nsTSubstring<char16_t> const &,JS::Handle<JS::Value>,mozilla::ErrorResult &) [dom/html/HTMLCanvasElement.cpp:910]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #09: static bool mozilla::dom::HTMLCanvasElement_Binding::getContext(struct JSContext *, class JS::Handle<JSObject *>, class mozilla::dom::HTMLCanvasElement *, const class JSJitMethodCallArgs & const) [s3:gecko-generated-sources:249cdd924507a01a6c77d6da61cd0975f0cba9610281fe9dbe1351c2b7b81e9aa5314be12863179f98254c5a777845cb3f8b50ed646571f455e2df7f2d52bed1/dom/bindings/HTMLCanvasElementBinding.cpp::289]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #10: mozilla::dom::binding_detail::GenericMethod<mozilla::dom::binding_detail::NormalThisPolicy,mozilla::dom::binding_detail::ThrowExceptions>(JSContext *,unsigned int,JS::Value *) [dom/bindings/BindingUtils.cpp:3144]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #11: CallJSNative(JSContext ,bool ()(JSContext *,unsigned int,JS::Value *),JS::CallArgs const &) [js/src/vm/Interpreter.cpp:440]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #12: js::InternalCallOrConstruct(JSContext *,JS::CallArgs const &,js::MaybeConstruct) [js/src/vm/Interpreter.cpp:532]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #13: static bool InternalCall(struct JSContext *, const class js::AnyInvokeArgs & const) [js/src/vm/Interpreter.cpp:587]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #14: static bool Interpret(struct JSContext *, class js::RunState & const) [js/src/vm/Interpreter.cpp:0]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #15: js::RunScript(JSContext *,js::RunState &) [js/src/vm/Interpreter.cpp:420]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #16: js::InternalCallOrConstruct(JSContext *,JS::CallArgs const &,js::MaybeConstruct) [js/src/vm/Interpreter.cpp:560]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #17: static bool InternalCall(struct JSContext *, const class js::AnyInvokeArgs & const) [js/src/vm/Interpreter.cpp:587]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #18: js::Call(JSContext *,JS::Handle<JS::Value>,JS::Handle<JS::Value>,js::AnyInvokeArgs const &,JS::MutableHandle<JS::Value>) [js/src/vm/Interpreter.cpp:603]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #19: js::ForwardingProxyHandler::call(JSContext *,JS::Handle<JSObject *>,JS::CallArgs const &) [js/src/proxy/Wrapper.cpp:162]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #20: js::CrossCompartmentWrapper::call(JSContext *,JS::Handle<JSObject *>,JS::CallArgs const &) [js/src/proxy/CrossCompartmentWrapper.cpp:238]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #21: xpc::JSXrayTraits::call(JSContext *,JS::Handle<JSObject *>,JS::CallArgs const &,js::Wrapper const &) [js/xpconnect/wrappers/XrayWrapper.h:213]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #22: xpc::XrayWrapper<js::CrossCompartmentWrapper,xpc::JSXrayTraits>::call(JSContext *,JS::Handle<JSObject *>,JS::CallArgs const &) [js/xpconnect/wrappers/XrayWrapper.cpp:2139]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #23: js::Proxy::call(JSContext *,JS::Handle<JSObject *>,JS::CallArgs const &) [js/src/proxy/Proxy.cpp:501]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #24: js::InternalCallOrConstruct(JSContext *,JS::CallArgs const &,js::MaybeConstruct) [js/src/vm/Interpreter.cpp:506]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #25: static bool InternalCall(struct JSContext *, const class js::AnyInvokeArgs & const) [js/src/vm/Interpreter.cpp:587]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #26: static bool js::jit::DoCallFallback(struct JSContext *, class js::jit::BaselineFrame *, class js::jit::ICCall_Fallback *, unsigned int, union JS::Value *, class JS::MutableHandle<JS::Value>) [js/src/jit/BaselineIC.cpp:3879]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #27: ??? (???:???)
02:32:22 INFO - GECKO(1436) | #28: ??? (???:???)
02:32:22 INFO - GECKO(1436) | #29: ??? (???:???)
02:32:22 INFO - GECKO(1436) | #30: ??? (???:???)
02:32:22 INFO - GECKO(1436) | #31: ??? (???:???)
02:32:22 INFO - GECKO(1436) | #32: js::jit::MaybeEnterJit(JSContext *,js::RunState &) [js/src/jit/Jit.cpp:168]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #33: js::RunScript(JSContext *,js::RunState &) [js/src/vm/Interpreter.cpp:405]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #34: js::InternalCallOrConstruct(JSContext *,JS::CallArgs const &,js::MaybeConstruct) [js/src/vm/Interpreter.cpp:560]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #35: static bool InternalCall(struct JSContext *, const class js::AnyInvokeArgs & const) [js/src/vm/Interpreter.cpp:587]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #36: js::Call(JSContext *,JS::Handle<JS::Value>,JS::Handle<JS::Value>,js::AnyInvokeArgs const &,JS::MutableHandle<JS::Value>) [js/src/vm/Interpreter.cpp:603]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #37: JS::Call(JSContext *,JS::Handle<JS::Value>,JS::Handle<JS::Value>,JS::HandleValueArray const &,JS::MutableHandle<JS::Value>) [js/src/jsapi.cpp:2623]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #38: mozilla::dom::Function::Call(JSContext *,JS::Handle<JS::Value>,nsTArray<JS::Value> const &,JS::MutableHandle<JS::Value>,mozilla::ErrorResult &) [s3:gecko-generated-sources:c9facbd9579eb30729ca64e87853e195a9229c02bafbc52c704c7a7650e09d2a3f236b08ed00a43d224ca7873df4e0d9ce1e79d589baff52a19e0fb15961f696/dom/bindings/FunctionBinding.cpp::41]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #39: mozilla::dom::Function::Call<nsCOMPtr<nsISupports> >(nsCOMPtr<nsISupports> const &,nsTArray<JS::Value> const &,JS::MutableHandle<JS::Value>,mozilla::ErrorResult &,char const *,mozilla::dom::CallbackObject::ExceptionHandling,JS::Realm *) [s3:gecko-generated-sources:a02fa665924a56a02d11add60a3735988fa505b8486552a814b17e8eed5d3a7b70007d1d317573bea6db8c30b9b6bccbf36c8f0e199937215335254f521bd084/dist/include/mozilla/dom/FunctionBinding.h::73]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #40: nsGlobalWindowInner::RunTimeoutHandler(mozilla::dom::Timeout *,nsIScriptContext *) [dom/base/nsGlobalWindowInner.cpp:6052]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #41: mozilla::dom::TimeoutManager::RunTimeout(mozilla::TimeStamp const &,mozilla::TimeStamp const &,bool) [dom/base/TimeoutManager.cpp:947]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #42: mozilla::dom::TimeoutExecutor::MaybeExecute() [dom/base/TimeoutExecutor.cpp:177]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #43: mozilla::dom::TimeoutExecutor::Run() [dom/base/TimeoutExecutor.cpp:233]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #44: mozilla::ThrottledEventQueue::Inner::ExecuteRunnable() [xpcom/threads/ThrottledEventQueue.cpp:231]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #45: mozilla::ThrottledEventQueue::Inner::Executor::Run() [xpcom/threads/ThrottledEventQueue.cpp:77]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #46: mozilla::SchedulerGroup::Runnable::Run() [xpcom/threads/SchedulerGroup.cpp:296]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #47: nsThread::ProcessNextEvent(bool,bool *) [xpcom/threads/nsThread.cpp:1162]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #48: NS_ProcessNextEvent(nsIThread *,bool) [xpcom/threads/nsThreadUtils.cpp:474]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #49: mozilla::ipc::MessagePump::Run(base::MessagePump::Delegate *) [ipc/glue/MessagePump.cpp:88]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #50: MessageLoop::RunInternal() [ipc/chromium/src/base/message_loop.cc:315]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #51: MessageLoop::RunHandler() [ipc/chromium/src/base/message_loop.cc:309]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #52: MessageLoop::Run() [ipc/chromium/src/base/message_loop.cc:291]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #53: nsBaseAppShell::Run() [widget/nsBaseAppShell.cpp:139]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #54: nsAppShell::Run() [widget/windows/nsAppShell.cpp:411]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #55: XRE_RunAppShell() [toolkit/xre/nsEmbedFunctions.cpp:908]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #56: mozilla::ipc::MessagePumpForChildProcess::Run(base::MessagePump::Delegate *) [ipc/glue/MessagePump.cpp:238]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #57: MessageLoop::RunInternal() [ipc/chromium/src/base/message_loop.cc:315]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #58: MessageLoop::RunHandler() [ipc/chromium/src/base/message_loop.cc:309]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #59: MessageLoop::Run() [ipc/chromium/src/base/message_loop.cc:291]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #60: XRE_InitChildProcess(int,char * * const,XREChildData const *) [toolkit/xre/nsEmbedFunctions.cpp:750]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #61: mozilla::BootstrapImpl::XRE_InitChildProcess(int,char * * const,XREChildData const *) [toolkit/xre/Bootstrap.cpp:61]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #62: NS_internal_main(int,char * *,char * *) [browser/app/nsBrowserApp.cpp:265]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #63: wmain [toolkit/xre/nsWindowsWMain.cpp:129]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #64: static int __scrt_common_main_seh() [f:/dd/vctools/crt/vcstartup/src/startup/exe_common.inl:288]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #65: kernel32.dll + 0x53c45
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #66: ntdll.dll + 0x637f5
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #67: ntdll.dll + 0x637c8
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | [Child 4216, Main Thread] WARNING: GLContext::InitWithPrefix failed!: file z:/build/build/src/gfx/gl/GLContext.cpp, line 315
02:32:22 INFO - GECKO(1436) | JavaScript warning: http://mochi.test:8888/tests/dom/canvas/test/webgl-mochitest/test_pixel_pack_buffer.html, line 135: Error: WebGL warning: <SetDimensions>: Failed to create WebGL context: WebGL creation failed:
02:32:22 INFO - GECKO(1436) | * tryNativeGL
02:32:22 INFO - GECKO(1436) | * Exhausted GL driver options.
02:32:22 INFO - GECKO(1436) | MEMORY STAT | vsize 691MB | vsizeMaxContiguous 535MB | residentFast 162MB | heapAllocated 17MB
02:32:22 INFO - TEST-OK | dom/canvas/test/webgl-mochitest/test_pixel_pack_buffer.html | took 1192ms
02:32:22 INFO - GECKO(1436) | ++DOMWINDOW == 47 (0DCEE400) [pid = 4216] [serial = 87] [outer = 014FD7A0]
02:32:22 INFO - TEST-UNEXPECTED-FAIL | dom/canvas/test/webgl-mochitest/test_pixel_pack_buffer.html | assertion count 1 is more than expected 0 assertions

Flags: needinfo?(jgilbert)
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glStencilOp'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glTexImage2D'.
02:31:38 INFO - GECKO(1436) | Can't find symbol 'glViewport'.
02:31:38 INFO - GECKO(1436) | [Child 4216, Main Thread] ###!!! ASSERTION: Failed to load symbols for GL.: 'Error', file z:/build/build/src/gfx/gl/GLContext.cpp, line 332
02:32:22 INFO - GECKO(1436) | #01: mozilla::gl::GLContext::Init() [gfx/gl/GLContext.cpp:311]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #02: mozilla::gl::GLContextProviderWGL::CreateHeadless(mozilla::gl::CreateContextFlags,nsTSubstring&lt;char> * const) [gfx/gl/GLContextProviderWGL.cpp:526]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #03: mozilla::gl::GLContextProviderWGL::CreateOffscreen(mozilla::gfx::IntSizeTyped&lt;mozilla::gfx::UnknownUnits> const &,mozilla::gl::SurfaceCaps const &,mozilla::gl::CreateContextFlags,nsTSubstring&lt;char> * const) [gfx/gl/GLContextProviderWGL.cpp:536]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #04: mozilla::WebGLContext::CreateAndInitGL(bool,std::vector&lt;mozilla::WebGLContext::FailureReason,std::allocator&lt;mozilla::WebGLContext::FailureReason> > * const) [dom/canvas/WebGLContext.cpp:590]
02:32:22 INFO -
02:32:22 INFO - GECKO(1436) | #05: mozilla::WebGLContext::SetDimensions(int,int) [dom/canvas/WebGLContext.cpp:843]

Woah, we shouldn't be hitting WGL!

Flags: needinfo?(jgilbert)

We actually explicitly ask for WGL for that test.

Pushed by jgilbert@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/cf7f4cea93be
More precise GL symbol loading. r=lsalzman
Status: NEW → RESOLVED
Closed: 1 year ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla67
Blocks: 1420745
Blocks: 1532456
You need to log in before you can comment on or make changes to this bug.