Gstreamer memory leak: how do I hunt it down?

Sebastian Dröge sebastian at centricular.com
Mon Dec 19 09:18:27 UTC 2016


On Sun, 2016-12-18 at 17:58 +0200, Graham Leggett wrote:
> On 18 Dec 2016, at 10:57 AM, Sebastian Dröge <sebastian at centricular.c
> om> wrote:
> 
> > > 0:01:01.779640164  1232 0x740f7580 TRACE        GST_REFCOUNTING
> > > gstobject.c:275:gst_object_unref:<allocatorsysmem0> 0x74204818
> > > unref
> > > 5958->5957
> > 
> > This suggests that something somewhere is leaking system memory
> > GstMemory. Each of them has a reference to its allocator, so you
> > seem
> > to have about 6000 of them around currently.
> > It's not the allocator that is leaked here though.
> 
> This makes more sense now.
> 
> > Use valgrind, valgrind's massif or the GStreamer leak tracer for
> > tracking this down. Also before doing anything like that, make your
> > pipeline as minimal as possible.
> 
> Narrowed it down to the tsparse element. 
> 
> Valgrind doesn’t run on a pi, and neither does LeakAnalyzer, so I’m
> stuck with the gstreamer leak tracer. Is this documented anywhere?

Do you have a way to reproduce it? Getting the stream and reproducing
it with that stream on a machine that can run valgrind would seem like
the best option then.

-- 
Sebastian Dröge, Centricular Ltd · http://www.centricular.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 963 bytes
Desc: This is a digitally signed message part
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20161219/5ca29a06/attachment.sig>


More information about the gstreamer-devel mailing list