Closed
Bug 1797099
Opened 2 years ago
Closed 2 years ago
Assertion failure: inverted (Attempted to get the inverse of a non-invertible matrix), at /builds/worker/workspace/obj-build/dist/include/mozilla/gfx/Matrix.h:277
Categories
(Core :: Graphics: Canvas2D, defect)
Tracking
()
VERIFIED
FIXED
108 Branch
Tracking | Status | |
---|---|---|
firefox108 | --- | verified |
People
(Reporter: jkratzer, Assigned: lsalzman)
References
(Blocks 1 open bug)
Details
(Keywords: testcase, Whiteboard: [bugmon:confirm])
Attachments
(2 files)
Testcase found while fuzzing mozilla-central rev d1982cee06ca (built with: --enable-debug --enable-fuzzing).
Testcase can be reproduced using the following commands:
$ pip install fuzzfetch grizzly-framework
$ python -m fuzzfetch --build d1982cee06ca --debug --fuzzing -n firefox
$ python -m grizzly.replay ./firefox/firefox testcase.html
Assertion failure: inverted (Attempted to get the inverse of a non-invertible matrix), at /builds/worker/workspace/obj-build/dist/include/mozilla/gfx/Matrix.h:277
==150196==ERROR: UndefinedBehaviorSanitizer: SEGV on unknown address 0x000000000000 (pc 0x7fddeaedbba9 bp 0x7ffddb08d700 sp 0x7ffddb08d700 T150196)
==150196==The signal is caused by a WRITE memory access.
==150196==Hint: address points to the zero page.
#0 0x7fddeaedbba9 in mozilla::gfx::BaseMatrix<float>::Inverse() const /builds/worker/workspace/obj-build/dist/include/mozilla/gfx/Matrix.h:276:5
#1 0x7fddeaed9b06 in mozilla::gfx::DrawTargetWebgl::SharedContext::DrawRectAccel(mozilla::gfx::RectTyped<mozilla::gfx::UnknownUnits, float> const&, mozilla::gfx::Pattern const&, mozilla::gfx::DrawOptions const&, mozilla::Maybe<mozilla::gfx::DeviceColor>, RefPtr<mozilla::gfx::TextureHandle>*, bool, bool, bool, bool, mozilla::gfx::StrokeOptions const*) /dom/canvas/DrawTargetWebgl.cpp:1991:42
#2 0x7fddeaed688f in mozilla::gfx::DrawTargetWebgl::DrawRect(mozilla::gfx::RectTyped<mozilla::gfx::UnknownUnits, float> const&, mozilla::gfx::Pattern const&, mozilla::gfx::DrawOptions const&, mozilla::Maybe<mozilla::gfx::DeviceColor>, RefPtr<mozilla::gfx::TextureHandle>*, bool, bool, bool, bool, mozilla::gfx::StrokeOptions const*) /dom/canvas/DrawTargetWebgl.cpp:1395:30
#3 0x7fddeaedc7e9 in mozilla::gfx::DrawTargetWebgl::FillRect(mozilla::gfx::RectTyped<mozilla::gfx::UnknownUnits, float> const&, mozilla::gfx::Pattern const&, mozilla::gfx::DrawOptions const&) /dom/canvas/DrawTargetWebgl.cpp:2134:5
#4 0x7fddeaf0673c in mozilla::dom::AdjustedTarget::FillRect(mozilla::gfx::RectTyped<mozilla::gfx::UnknownUnits, float> const&, mozilla::gfx::Pattern const&, mozilla::gfx::DrawOptions const&) /dom/canvas/CanvasRenderingContext2D.cpp:694:14
#5 0x7fddeaf059ea in mozilla::dom::CanvasRenderingContext2D::FillRect(double, double, double, double) /dom/canvas/CanvasRenderingContext2D.cpp:2774:10
#6 0x7fddea2c5dac in mozilla::dom::CanvasRenderingContext2D_Binding::fillRect(JSContext*, JS::Handle<JSObject*>, void*, JSJitMethodCallArgs const&) /builds/worker/workspace/obj-build/dom/bindings/CanvasRenderingContext2DBinding.cpp:6091:24
#7 0x7fddeae1a1fc in bool mozilla::dom::binding_detail::GenericMethod<mozilla::dom::binding_detail::NormalThisPolicy, mozilla::dom::binding_detail::ThrowExceptions>(JSContext*, unsigned int, JS::Value*) /dom/bindings/BindingUtils.cpp:3287:13
#8 0x7fddf05157ec in CallJSNative(JSContext*, bool (*)(JSContext*, unsigned int, JS::Value*), js::CallReason, JS::CallArgs const&) /js/src/vm/Interpreter.cpp:459:13
#9 0x7fddf0515111 in js::InternalCallOrConstruct(JSContext*, JS::CallArgs const&, js::MaybeConstruct, js::CallReason) /js/src/vm/Interpreter.cpp:547:12
#10 0x7fddf050c478 in CallFromStack /js/src/vm/Interpreter.cpp:619:10
#11 0x7fddf050c478 in Interpret(JSContext*, js::RunState&) /js/src/vm/Interpreter.cpp:3375:16
#12 0x7fddf050352d in js::RunScript(JSContext*, js::RunState&) /js/src/vm/Interpreter.cpp:431:13
#13 0x7fddf051500d in js::InternalCallOrConstruct(JSContext*, JS::CallArgs const&, js::MaybeConstruct, js::CallReason) /js/src/vm/Interpreter.cpp:579:13
#14 0x7fddf051654c in js::Call(JSContext*, JS::Handle<JS::Value>, JS::Handle<JS::Value>, js::AnyInvokeArgs const&, JS::MutableHandle<JS::Value>, js::CallReason) /js/src/vm/Interpreter.cpp:646:8
#15 0x7fddef17b00c in JS::Call(JSContext*, JS::Handle<JS::Value>, JS::Handle<JS::Value>, JS::HandleValueArray const&, JS::MutableHandle<JS::Value>) /js/src/vm/CallAndConstruct.cpp:117:10
#16 0x7fddeab0c289 in mozilla::dom::EventListener::HandleEvent(mozilla::dom::BindingCallContext&, JS::Handle<JS::Value>, mozilla::dom::Event&, mozilla::ErrorResult&) /builds/worker/workspace/obj-build/dom/bindings/EventListenerBinding.cpp:62:8
#17 0x7fddeb3dc536 in void mozilla::dom::EventListener::HandleEvent<mozilla::dom::EventTarget*>(mozilla::dom::EventTarget* const&, mozilla::dom::Event&, mozilla::ErrorResult&, char const*, mozilla::dom::CallbackObject::ExceptionHandling, JS::Realm*) /builds/worker/workspace/obj-build/dist/include/mozilla/dom/EventListenerBinding.h:65:12
#18 0x7fddeb3dc25d in mozilla::EventListenerManager::HandleEventSubType(mozilla::EventListenerManager::Listener*, mozilla::dom::Event*, mozilla::dom::EventTarget*) /dom/events/EventListenerManager.cpp:1310:43
#19 0x7fddeb3dcf07 in mozilla::EventListenerManager::HandleEventInternal(nsPresContext*, mozilla::WidgetEvent*, mozilla::dom::Event**, mozilla::dom::EventTarget*, nsEventStatus*, bool) /dom/events/EventListenerManager.cpp:1506:17
#20 0x7fddeb3d1e44 in HandleEvent /dom/events/EventListenerManager.h:395:5
#21 0x7fddeb3d1e44 in mozilla::EventTargetChainItem::HandleEvent(mozilla::EventChainPostVisitor&, mozilla::ELMCreationDetector&) /dom/events/EventDispatcher.cpp:348:17
#22 0x7fddeb3d1392 in mozilla::EventTargetChainItem::HandleEventTargetChain(nsTArray<mozilla::EventTargetChainItem>&, mozilla::EventChainPostVisitor&, mozilla::EventDispatchingCallback*, mozilla::ELMCreationDetector&) /dom/events/EventDispatcher.cpp:550:16
#23 0x7fddeb3d3c31 in mozilla::EventDispatcher::Dispatch(nsISupports*, nsPresContext*, mozilla::WidgetEvent*, mozilla::dom::Event*, nsEventStatus*, mozilla::EventDispatchingCallback*, nsTArray<mozilla::dom::EventTarget*>*) /dom/events/EventDispatcher.cpp:1119:11
#24 0x7fddeb3d66a6 in mozilla::EventDispatcher::DispatchDOMEvent(nsISupports*, mozilla::WidgetEvent*, mozilla::dom::Event*, nsPresContext*, nsEventStatus*) /dom/events/EventDispatcher.cpp
#25 0x7fdde9941ddd in nsINode::DispatchEvent(mozilla::dom::Event&, mozilla::dom::CallerType, mozilla::ErrorResult&) /dom/base/nsINode.cpp:1373:17
#26 0x7fdde9474d5a in nsContentUtils::DispatchEvent(mozilla::dom::Document*, nsISupports*, nsTSubstring<char16_t> const&, mozilla::CanBubble, mozilla::Cancelable, mozilla::Composed, mozilla::Trusted, bool*, mozilla::ChromeOnlyDispatch) /dom/base/nsContentUtils.cpp:4499:28
#27 0x7fdde9474b57 in nsContentUtils::DispatchTrustedEvent(mozilla::dom::Document*, nsISupports*, nsTSubstring<char16_t> const&, mozilla::CanBubble, mozilla::Cancelable, mozilla::Composed, bool*) /dom/base/nsContentUtils.cpp:4469:10
#28 0x7fdde96b6a8d in mozilla::dom::Document::DispatchContentLoadedEvents() /dom/base/Document.cpp:7843:3
#29 0x7fdde976c92b in applyImpl<mozilla::dom::Document, void (mozilla::dom::Document::*)()> /builds/worker/workspace/obj-build/dist/include/nsThreadUtils.h:1147:12
#30 0x7fdde976c92b in apply<mozilla::dom::Document, void (mozilla::dom::Document::*)()> /builds/worker/workspace/obj-build/dist/include/nsThreadUtils.h:1153:12
#31 0x7fdde976c92b in mozilla::detail::RunnableMethodImpl<mozilla::dom::Document*, void (mozilla::dom::Document::*)(), true, (mozilla::RunnableKind)0>::Run() /builds/worker/workspace/obj-build/dist/include/nsThreadUtils.h:1200:13
#32 0x7fdde7c34562 in mozilla::SchedulerGroup::Runnable::Run() /xpcom/threads/SchedulerGroup.cpp:140:20
#33 0x7fdde7c3e8c4 in mozilla::RunnableTask::Run() /xpcom/threads/TaskController.cpp:538:16
#34 0x7fdde7c39ec1 in mozilla::TaskController::DoExecuteNextTaskOnlyMainThreadInternal(mozilla::detail::BaseAutoLock<mozilla::Mutex&> const&) /xpcom/threads/TaskController.cpp:851:26
#35 0x7fdde7c38a1a in mozilla::TaskController::ExecuteNextTaskOnlyMainThreadInternal(mozilla::detail::BaseAutoLock<mozilla::Mutex&> const&) /xpcom/threads/TaskController.cpp:683:15
#36 0x7fdde7c38d75 in mozilla::TaskController::ProcessPendingMTTask(bool) /xpcom/threads/TaskController.cpp:461:36
#37 0x7fdde7c42216 in operator() /xpcom/threads/TaskController.cpp:187:37
#38 0x7fdde7c42216 in mozilla::detail::RunnableFunction<mozilla::TaskController::InitializeInternal()::$_2>::Run() /builds/worker/workspace/obj-build/dist/include/nsThreadUtils.h:531:5
#39 0x7fdde7c57b17 in nsThread::ProcessNextEvent(bool, bool*) /xpcom/threads/nsThread.cpp:1204:16
#40 0x7fdde7c5e31d in NS_ProcessNextEvent(nsIThread*, bool) /xpcom/threads/nsThreadUtils.cpp:465:10
#41 0x7fdde884d806 in mozilla::ipc::MessagePump::Run(base::MessagePump::Delegate*) /ipc/glue/MessagePump.cpp:85:21
#42 0x7fdde8771577 in MessageLoop::RunInternal() /ipc/chromium/src/base/message_loop.cc:381:10
#43 0x7fdde8771482 in RunHandler /ipc/chromium/src/base/message_loop.cc:374:3
#44 0x7fdde8771482 in MessageLoop::Run() /ipc/chromium/src/base/message_loop.cc:356:3
#45 0x7fddecca2cb8 in nsBaseAppShell::Run() /widget/nsBaseAppShell.cpp:150:27
#46 0x7fddeeeb61fb in XRE_RunAppShell() /toolkit/xre/nsEmbedFunctions.cpp:880:20
#47 0x7fdde884e6fa in mozilla::ipc::MessagePumpForChildProcess::Run(base::MessagePump::Delegate*) /ipc/glue/MessagePump.cpp:235:9
#48 0x7fdde8771577 in MessageLoop::RunInternal() /ipc/chromium/src/base/message_loop.cc:381:10
#49 0x7fdde8771482 in RunHandler /ipc/chromium/src/base/message_loop.cc:374:3
#50 0x7fdde8771482 in MessageLoop::Run() /ipc/chromium/src/base/message_loop.cc:356:3
#51 0x7fddeeeb57de in XRE_InitChildProcess(int, char**, XREChildData const*) /toolkit/xre/nsEmbedFunctions.cpp:739:34
#52 0x55be1c6b4c19 in content_process_main /browser/app/../../ipc/contentproc/plugin-container.cpp:57:28
#53 0x55be1c6b4c19 in main /browser/app/nsBrowserApp.cpp:357:18
#54 0x7fde00315d8f in __libc_start_call_main csu/../sysdeps/nptl/libc_start_call_main.h:58:16
#55 0x7fde00315e3f in __libc_start_main csu/../csu/libc-start.c:392:3
#56 0x55be1c68a8dc in _start (/home/jkratzer/builds/m-c-20221024093150-fuzzing-debug/firefox-bin+0x168dc) (BuildId: f410d6172ef7f2702dfb21f49bdf05e8f1092175)
UndefinedBehaviorSanitizer can not provide additional info.
SUMMARY: UndefinedBehaviorSanitizer: SEGV /builds/worker/workspace/obj-build/dist/include/mozilla/gfx/Matrix.h:276:5 in mozilla::gfx::BaseMatrix<float>::Inverse() const
==150196==ABORTING
Reporter | ||
Comment 1•2 years ago
|
||
Updated•2 years ago
|
Severity: -- → S3
Flags: needinfo?(lsalzman)
Assignee | ||
Comment 2•2 years ago
|
||
Updated•2 years ago
|
Assignee: nobody → lsalzman
Status: NEW → ASSIGNED
Assignee | ||
Updated•2 years ago
|
Flags: needinfo?(lsalzman)
Pushed by lsalzman@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/41e2283d971a
Ensure the SurfacePattern transform is invertible. r=aosmond
Comment 4•2 years ago
|
||
bugherder |
Status: ASSIGNED → RESOLVED
Closed: 2 years ago
status-firefox108:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → 108 Branch
Comment 5•2 years ago
|
||
Bugmon Analysis
Verified bug as fixed on rev mozilla-central 20221026034746-8a97830c36c3.
Removing bugmon keyword as no further action possible. Please review the bug and re-add the keyword for further analysis.
You need to log in
before you can comment on or make changes to this bug.
Description
•