[mythtv-users] Mythfrontend memory leak on master

Bill Meek keemllib at gmail.com
Wed Jun 4 20:18:08 UTC 2014


On 06/04/2014 02:49 PM, Timothy Krantz wrote:
> Hi,
> I seem to be experiencing a memory leak during playback with the latest
> master code.  I am not sure how long it has been going on.  It does not
> happen during playback of all content, just some of it.  I first noticed it
> on my ARM  based frontend and was originally concerned that it had to do
> with the arm port of the code.  Today though I was able to confirm that
> certain  programs cause the same issue on both arm and intel, and others do
> not (one either platform).  It is consistent, recordings either leak memory
> on both or on neither.  It is just much more obvious on my arm frontend
> because it has only 1 gig of memory, my intel has 4gig.
>
> In particular, and this is just based on what I have currently recorded,
> programs recorded digitally on my local ABC affiliate leak memory upon
> playback.  To be even more precise, my recordings of "Black Box" leak
> memory.  This is observed so far by using top.  The RES column for
> mythfrontend increases on every refresh and stays at that level after
> playback is completed.  Starting another episode of "Black Box" and the
> memory usage continues to climb.  After more than an hour it had gone from
> 262744 to 2.1gig.
>
> I was wondering if anyone else had copies of recordings from ABC, in
> particular of "Black Box" and could attempt to reproduce this behavior.  Or
> if anyone else is seeing possible memory leaks using master during playback
> of other material.
>
> I vaguely recall a thread some time back mentioning valgrind as the
> appropriate method of documenting a memory leak.  I am not yet familiar with
> valgrind.  Is this still the proper tool?

Hi,

Somewhat glad to hear you're having the problem. I've seen it too. I'm
just starting with valgrind and here's the command line I've used:

valgrind --leak-check=full --error-limit=no --show-reachable=yes --log-file=/tmp/vg.out \
     /usr/local/bin/mythfrontend -v general,playback,libav --loglevel=debug --quiet --logpath=/tmp

I don't understand the significance of possibly lost memory, but that's
where the bulk of mine was.

The output of my 1st run was huge and also had a core file, so I tossed it.
I'll pastebin the last ~50 lines on my next run (and look to see if it is
more pronounced on some channels.)

Also, when I ran it, playback never started. I did rebuild with  --enable-valgrind
first.

Running: v0.28-pre-1470-gb79b7ae.

-- 
Bill


More information about the mythtv-users mailing list