[Webkit-unassigned] [Bug 219653] New: [GStreamer] proxy.getAvailableBuffer() can only be called from the compositor thread

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Dec 8 13:17:32 PST 2020


https://bugs.webkit.org/show_bug.cgi?id=219653

            Bug ID: 219653
           Summary: [GStreamer] proxy.getAvailableBuffer() can only be
                    called from the compositor thread
           Product: WebKit
           Version: WebKit Nightly Build
          Hardware: Unspecified
                OS: Unspecified
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: WebKitGTK
          Assignee: webkit-unassigned at lists.webkit.org
          Reporter: aboya at igalia.com
                CC: bugs-noreply at webkitgtk.org

void MediaPlayerPrivateGStreamer::pushTextureToCompositor()
{
    [...]
    auto internalCompositingOperation = [this](TextureMapperPlatformLayerProxy& proxy, std::unique_ptr<GstVideoFrameHolder>&& frameHolder) {
        [...]
        if (frameHolder->hasMappedTextures()) {
            [...]
        } else {
            layerBuffer = proxy.getAvailableBuffer(frameHolder->size(), GL_DONT_CARE);

This code runs inside the streaming thread of the video sink (see the stack trace below). The `else` case is not intended to hit in a default desktop build of WebKit, but if it does, it will because TextureMapperPlatformLayerProxy::getAvailableBuffer() expects to be run from the compositor thread.

ASSERTION FAILED: m_compositorThread == &Thread::current()
#0  WTFCrash() () at ../../Source/WTF/wtf/Assertions.cpp:295
#1  0x00007f59cd0479b7 in CRASH_WITH_INFO(...) () at DerivedSources/ForwardingHeaders/wtf/Assertions.h:713
#2  0x00007f59ce74b47c in WebCore::TextureMapperPlatformLayerProxy::getAvailableBuffer(WebCore::IntSize const&, int) (this=0x7f595c5a2820, size=..., internalFormat=4352) at ../../Source/WebCore/platform/graphics/texmap/TextureMapperPlatformLayerProxy.cpp:140
#3  0x00007f59d1b5fd63 in operator()(WebCore::TextureMapperPlatformLayerProxy&, std::unique_ptr<WebCore::GstVideoFrameHolder, std::default_delete<WebCore::GstVideoFrameHolder> >&&) const (__closure=0x7f58897f80a8, proxy=..., frameHolder=...) at ../../Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:2912
#4  0x00007f59d1b60015 in operator()(WebCore::TextureMapperPlatformLayerProxy&) const (__closure=0x7f58897f80a0, proxy=...) at ../../Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:2952
#5  0x00007f59d1b6012e in WebCore::MediaPlayerPrivateGStreamer::pushTextureToCompositor() (this=0x7f592439b000) at ../../Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:2957
#6  0x00007f59d1b6102e in WebCore::MediaPlayerPrivateGStreamer::triggerRepaint(_GstSample*) (this=0x7f592439b000, sample=0x562457872120 [GstSample]) at ../../Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:3117
#7  0x00007f59d1b45030 in operator()(GstElement*, WebCore::MediaPlayerPrivateGStreamer*) const (__closure=0x0, sink=0x5624575a2c00 [GstAppSink|webkit-gl-video-appsink], player=0x7f592439b000) at ../../Source/WebCore/platform/graphics/gstreamer/GLVideoSinkGStreamer.cpp:235
#8  0x00007f59d1b45082 in _FUN(GstElement*, WebCore::MediaPlayerPrivateGStreamer*) () at ../../Source/WebCore/platform/graphics/gstreamer/GLVideoSinkGStreamer.cpp:235
#9  0x00007f59b5a95f75 in ffi_call_unix64 () at ../src/x86/unix64.S:101
#10 0x00007f59b5a95369 in ffi_call_int (cif=<optimized out>, fn=<optimized out>, rvalue=<optimized out>, avalue=<optimized out>, closure=<optimized out>) at ../src/x86/ffi64.c:669
#11 0x00007f59b75658da in g_cclosure_marshal_generic_va (closure=<optimized out>, return_value=<optimized out>, instance=<optimized out>, args_list=<optimized out>, marshal_data=<optimized out>, n_params=<optimized out>, param_types=<optimized out>) at ../gobject/gclosure.c:1614
#12 0x00007f59b7564b46 in _g_closure_invoke_va (closure=closure at entry=0x562457326370, return_value=return_value at entry=0x7f58897f8580, instance=instance at entry=0x5624575a2c00, args=args at entry=0x7f58897f8630, n_params=0, param_types=0x0) at ../gobject/gclosure.c:873
#13 0x00007f59b757db5f in g_signal_emit_valist (instance=0x5624575a2c00, signal_id=<optimized out>, detail=0, var_args=var_args at entry=0x7f58897f8630) at ../gobject/gsignal.c:3403
#14 0x00007f59b757dd43 in g_signal_emit (instance=instance at entry=0x5624575a2c00, signal_id=<optimized out>, detail=detail at entry=0) at ../gobject/gsignal.c:3550
#15 0x00007f59b7f40c9c in gst_app_sink_preroll (psink=0x5624575a2c00 [GstAppSink|webkit-gl-video-appsink], buffer=<optimized out>) at ../gst-libs/gst/app/gstappsink.c:840
#16 0x00007f59b7eed653 in gst_base_sink_do_preroll (sink=sink at entry=0x5624575a2c00 [GstAppSink|webkit-gl-video-appsink], obj=obj at entry=0x7f594c0155a0 [GstBuffer]) at ../libs/gst/base/gstbasesink.c:2503
#17 0x00007f59b7eee10c in gst_base_sink_do_sync (basesink=basesink at entry=0x5624575a2c00 [GstAppSink|webkit-gl-video-appsink], obj=obj at entry=0x7f594c0155a0 [GstBuffer], late=late at entry=0x7f58897f8960, step_end=step_end at entry=0x7f58897f8964) at ../libs/gst/base/gstbasesink.c:2728

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20201208/27ff3072/attachment.htm>


More information about the webkit-unassigned mailing list