GNOME Bugzilla – Bug 775993
validate: Deadlock when doing PAUSE->PLAYING dance on BUFFERING messages while transcoding in filesink
Last modified: 2018-11-03 12:38:32 UTC
Created attachment 341827 [details] [review] validate: transcode: No buffering handling when the sink is not synced on the clock In gst-validate-transcoder-1.0 we respect do the BUFFERING message and PAUSE the pipeline when starting buffering and go back to PLAYING when this is done, and that even if the sink is not synchronized on the clock. Validate test: validate.http.transcode.to_vorbis_and_vp8_in_webm.raw_video_mkv In racy/rare conditions we get a deadlock when `prerolling` going to PAUSED with the following stack trace:
+ Trace 236968
Thread 6 (Thread 0x7fbb541e8700 (LWP 21847))
Thread 5 (Thread 0x7fbb537cd700 (LWP 21853))
Thread 4 (Thread 0x7fbb529ca700 (LWP 21860))
Thread 3 (Thread 0x7fbb51610700 (LWP 21865))
Thread 2 (Thread 0x7fbb50e0f700 (LWP 21868))
Going to PAUSED when BUFFERING on a pipeline that is not sync on the clock is useless so I attach here a patch that removes that behaviour in -validate but this case should still work and defenitely not deadlock.
Review of attachment 341827 [details] [review]: ::: validate/tools/gst-validate-transcoding.c @@ +478,3 @@ + g_object_class_find_property (G_OBJECT_GET_CLASS (sink), "sync"); + + if (spec) { We should also not buffer if the sink doesn't have a "sync" property ?
(In reply to Edward Hervey from comment #1) > Review of attachment 341827 [details] [review] [review]: > > ::: validate/tools/gst-validate-transcoding.c > @@ +478,3 @@ > + g_object_class_find_property (G_OBJECT_GET_CLASS (sink), "sync"); > + > + if (spec) { > > We should also not buffer if the sink doesn't have a "sync" property ? Well, who knows in that case? :)
Comment on attachment 341827 [details] [review] validate: transcode: No buffering handling when the sink is not synced on the clock Pushed with suggested change about missing 'sync' property commit ca85c454829ae8effa31551d56735e5ec2f5a3f6 Author: Thibault Saunier <tsaunier@gnome.org> Date: Mon Dec 12 12:27:42 2016 -0300 validate: transcode: No buffering handling when the sink is not synced on the clock It makes no sense to pause the pipeline and wait for buffering to be done when the pipeline is just processing the data as it comes in without synchronizing on the clock.
What if a child of the sink bin has the "sync" property? ;) Do we know why it deadlocks?
-- GitLab Migration Automatic Message -- This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/gstreamer/gstreamer/issues/209.