GNOME Bugzilla – Bug 653091
[dv1394src] Make the internal clock thread-safe
Last modified: 2011-06-24 19:03:01 UTC
Created attachment 190354 [details] [review] make the internal clock thread safe The internal clock is not thread safe and in some conditions an false overflow of the cycle timer can be detected.
Behaviour example: pipeline with e.g. dv1394src and alsasink freezes after some time. Several clock timing jumps can be seen before the freeze, running time and timestamping gets affected as well: 0:00:32.044433901 24339 0xa001ed8 LOG 1394clock gst1394clock.c:136:gst_1394_clock_get_internal_time:<dv1394clock> result 0:03:08.724750000 0:00:32.044448560 24339 0xa001ed8 DEBUG GST_CLOCK gstclock.c:955:gst_clock_get_internal_time:<dv1394clock> internal time 0:03:08.724750000 0:00:32.044462655 24339 0xa001ed8 DEBUG GST_CLOCK gstclock.c:1000:gst_clock_get_time:<dv1394clock> adjusted time 0:03:08.724750000 0:00:32.044475218 24339 0xa001ed8 DEBUG GST_CLOCK gstsystemclock.c:680:gst_system_clock_id_wait_jitter_unlocked: entry 0xa027188 finished, diff -250000 0:00:32.044488892 24339 0xa001ed8 DEBUG GST_CLOCK gstclock.c:514:gst_clock_id_wait:<dv1394clock> done waiting entry 0xa027188, res: 0 0:02:38.611387980 24339 0xa001e78 LOG 1394clock gst1394clock.c:121:gst_1394_clock_get_internal_time:<dv1394clock> overflow 2037015771 to 1989648722 0:02:38.611431236 24339 0xa001e78 LOG 1394clock gst1394clock.c:136:gst_1394_clock_get_internal_time:<dv1394clock> result 0:05:15.303250000 (this is an *unedited* log portion) Test pipeline: GST_DEBUG_NO_COLOR=1 GST_DEBUG=*CLOCK:5,1394clock:5 gst-launch-0.10 dv1394src ! identity ! dvdemux name=demux ! queue ! dvdec ! ffmpegcolorspace ! xvimagesink demux. ! queue ! audioconvert ! alsasink device=hw:0
Pushed, thanks.