Closed Bug 1776231 Opened 2 years ago Closed 2 years ago

Hit MOZ_CRASH(attempt to add with overflow) at /third_party/rust/wgpu-core/src/device/mod.rs:869

Categories

(Core :: Graphics: WebGPU, defect)

x86_64
Linux
defect

Tracking

()

VERIFIED FIXED

People

(Reporter: jkratzer, Unassigned)

References

(Blocks 2 open bugs)

Details

(Keywords: testcase, Whiteboard: [bugmon:bisected,confirmed])

Attachments

(1 file)

Testcase found while fuzzing mozilla-central rev f6c16b5b6942 (built with: --enable-debug --enable-fuzzing).

Testcase can be reproduced using the following commands:

$ pip install fuzzfetch grizzly-framework
$ python -m fuzzfetch --build f6c16b5b6942 --debug --fuzzing -n firefox
$ python -m grizzly.replay ./firefox/firefox testcase.html
Hit MOZ_CRASH(attempt to add with overflow) at /third_party/rust/wgpu-core/src/device/mod.rs:869

    ==2602064==ERROR: UndefinedBehaviorSanitizer: SEGV on unknown address 0x000000000000 (pc 0x7f31c51f7245 bp 0x7f31a816a880 sp 0x7f31a816a870 T2602223)
    ==2602064==The signal is caused by a WRITE memory access.
    ==2602064==Hint: address points to the zero page.
        #0 0x7f31c51f7245 in MOZ_Crash /builds/worker/workspace/obj-build/dist/include/mozilla/Assertions.h:261:3
        #1 0x7f31c51f7245 in RustMozCrash /mozglue/static/rust/wrappers.cpp:18:3
        #2 0x7f31c51f71c4 in mozglue_static::panic_hook::h201fcce9357271b1 /mozglue/static/rust/lib.rs:91:9
        #3 0x7f31c51f6c2b in core::ops::function::Fn::call::hb8dbd583e2536d4a /rustc/fe5b13d681f25ee6474be29d748c65adcd91f69e/library/core/src/ops/function.rs:70:5
        #4 0x7f31c619ec8f in std::panicking::rust_panic_with_hook::habfdcc2e90f9fd4c /rustc/fe5b13d681f25ee6474be29d748c65adcd91f69e/library/std/src/panicking.rs:702:17
        #5 0x7f31c619ea88 in std::panicking::begin_panic_handler::_$u7b$$u7b$closure$u7d$$u7d$::he054b2a83a51d2cd /rustc/fe5b13d681f25ee6474be29d748c65adcd91f69e/library/std/src/panicking.rs:586:13
        #6 0x7f31c619b903 in std::sys_common::backtrace::__rust_end_short_backtrace::ha48b94ab49b30915 /rustc/fe5b13d681f25ee6474be29d748c65adcd91f69e/library/std/src/sys_common/backtrace.rs:138:18
        #7 0x7f31c619e7f8 in rust_begin_unwind /rustc/fe5b13d681f25ee6474be29d748c65adcd91f69e/library/std/src/panicking.rs:584:5
        #8 0x7f31bb9d5aa2 in core::panicking::panic_fmt::h366d3a309ae17c94 /rustc/fe5b13d681f25ee6474be29d748c65adcd91f69e/library/core/src/panicking.rs:143:14
        #9 0x7f31bb9d596c in core::panicking::panic::h8705e81f284be8a5 /rustc/fe5b13d681f25ee6474be29d748c65adcd91f69e/library/core/src/panicking.rs:48:5
        #10 0x7f31c4578a80 in wgpu_server_texture_action /gfx/wgpu_bindings/src/server.rs
        #11 0x7f31bf185f6e in mozilla::webgpu::WebGPUParent::RecvTextureAction(unsigned long, unsigned long, mozilla::ipc::ByteBuf const&) /dom/webgpu/ipc/WebGPUParent.cpp:917:3
        #12 0x7f31bf198e8a in mozilla::webgpu::PWebGPUParent::OnMessageReceived(IPC::Message const&) /builds/worker/workspace/obj-build/ipc/ipdl/PWebGPUParent.cpp:364:80
        #13 0x7f31bd2a41ee in mozilla::gfx::PCanvasManagerParent::OnMessageReceived(IPC::Message const&) /builds/worker/workspace/obj-build/ipc/ipdl/PCanvasManagerParent.cpp:214:32
        #14 0x7f31bc954fd1 in mozilla::ipc::MessageChannel::DispatchAsyncMessage(mozilla::ipc::ActorLifecycleProxy*, IPC::Message const&) /ipc/glue/MessageChannel.cpp:1749:25
        #15 0x7f31bc951b25 in mozilla::ipc::MessageChannel::DispatchMessage(mozilla::ipc::ActorLifecycleProxy*, mozilla::UniquePtr<IPC::Message, mozilla::DefaultDelete<IPC::Message> >) /ipc/glue/MessageChannel.cpp:1674:9
        #16 0x7f31bc9526c6 in mozilla::ipc::MessageChannel::RunMessage(mozilla::ipc::ActorLifecycleProxy*, mozilla::ipc::MessageChannel::MessageTask&) /ipc/glue/MessageChannel.cpp:1474:3
        #17 0x7f31bc953a51 in mozilla::ipc::MessageChannel::MessageTask::Run() /ipc/glue/MessageChannel.cpp:1572:14
        #18 0x7f31bbd895b7 in nsThread::ProcessNextEvent(bool, bool*) /xpcom/threads/nsThread.cpp:1199:16
        #19 0x7f31bbd8fafd in NS_ProcessNextEvent(nsIThread*, bool) /xpcom/threads/nsThreadUtils.cpp:465:10
        #20 0x7f31bc95bd55 in mozilla::ipc::MessagePumpForNonMainThreads::Run(base::MessagePump::Delegate*) /ipc/glue/MessagePump.cpp:300:20
        #21 0x7f31bc882197 in MessageLoop::RunInternal() /ipc/chromium/src/base/message_loop.cc:380:10
        #22 0x7f31bc8820a2 in RunHandler /ipc/chromium/src/base/message_loop.cc:373:3
        #23 0x7f31bc8820a2 in MessageLoop::Run() /ipc/chromium/src/base/message_loop.cc:355:3
        #24 0x7f31bbd848e6 in nsThread::ThreadFunc(void*) /xpcom/threads/nsThread.cpp:384:10
        #25 0x7f31d1b8b557 in _pt_root /nsprpub/pr/src/pthreads/ptthread.c:201:5
        #26 0x7f31d28fd608 in start_thread /build/glibc-SzIz7B/glibc-2.31/nptl/pthread_create.c:477:8
        #27 0x7f31d24c4132 in __clone /build/glibc-SzIz7B/glibc-2.31/misc/../sysdeps/unix/sysv/linux/x86_64/clone.S:95
    
    UndefinedBehaviorSanitizer can not provide additional info.
    SUMMARY: UndefinedBehaviorSanitizer: SEGV /builds/worker/workspace/obj-build/dist/include/mozilla/Assertions.h:261:3 in MOZ_Crash
    ==2602064==ABORTING
Attached file Testcase

Bugmon Analysis
Verified bug as reproducible on mozilla-central 20220623121513-e0778405011f.
Unable to bisect testcase (Testcase reproduces on start build!):

Start: 1f6c9c348681b03a8af47fe6bd51a52cf00c89e5 (20210624023952)
End: f6c16b5b69425e0149db5741577fd0295c3ca0fe (20220623095414)
BuildFlags: BuildFlags(asan=False, tsan=False, debug=True, fuzzing=True, coverage=False, valgrind=False, no_opt=False, fuzzilli=False, nyx=False)

Whiteboard: [bugmon:confirm] → [bugmon:bisected,confirmed]

The severity field is not set for this bug.
:jimb, could you have a look please?

For more information, please visit auto_nag documentation.

Flags: needinfo?(jimb)
Depends on: 1784271
Flags: needinfo?(jimb)

Fixed by bug 1791297.

Status: NEW → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED

Bugmon Analysis
Verified bug as fixed on rev mozilla-central 20220922214429-4ce68ee50da2.
Removing bugmon keyword as no further action possible. Please review the bug and re-add the keyword for further analysis.

Status: RESOLVED → VERIFIED
Keywords: bugmon
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: