Hi folks, an update on my VLC measurement. I finally did that "vlc
-vvv", please see attachments for the stderr. I don't see anything
interesting there. But I did make snapshots of the vsize, rss, and the
"smaps" file under the /procfs/$PID/smaps --they are also attached. I
played the same video for less than 12 minutes then paused it. Then let
the window sit there like what I did before. The observation covered for
about 20 hours total.

The file "vlc-vvv-usage-wirawan2-Sisters_M16.txt" contains the output of
"ps faux" commands taken over regular interval (timestamp shown as cols
1-2) for this one process.

I plotted the vsize and rss from that ps output file (using pandas, in
case you're curious), I did see linear growth in the memory usage in
several stretches of time. And these stretches did not grow with the
same rate. I omitted the first line of the measurement because it is not
relevant (vlc was being started).

The smap files are timestamped with the UNIX time and the date/time--the
meaning should be clear from the filename. I supplied you three
snapshots:

* `smaps-1596468720-20200803T113241.txt`: about 5 minutes into the video 
playing (still running)
* `smaps-1596510832-20200803T231352.txt`: about 12 hours later (video paused)
* `smaps-1596540657-20200804T073057.txt`: about 20 hours later (video paused)

I did see some new memory regions allocated and it was not clear what
they are. But that's all the clue I could gather from my testings. Hope
all these help pinpointing the cause of the memory leak.

Here is an example analysis:

~~~
$ diff -y --width=200 <(grep -e '^[0-9a-f]+-[0-9a-f]+' -e 'Dirty'  -e Rss 
smaps-1596468720-20200803T113241.txt) <(grep -e '^[0-9a-f]+-[0-9a-f]+' -e 
'Dirty' -e Rss smaps-1596510832-20200803T231352.txt) |less
...

7fc19ec74000-7fc19ed74000 rw-s 00000000 00:1a 264                        /i915 
(deleted)           |    7fc188000000-7fc18b61a000 rw-p 00000000 00:00 0 
Rss:                 404 kB                                                     
                   |    Rss:               55400 kB
Shared_Dirty:          0 kB                                                     
                        Shared_Dirty:          0 kB
Private_Dirty:       404 kB                                                     
                   |    Private_Dirty:     55400 kB
7fc19ed74000-7fc19ed88000 rw-s 00000000 00:1a 802                        /i915 
(deleted)           |    7fc18b61a000-7fc18c000000 ---p 00000000 00:00 0 
Rss:                   4 kB                                                     
                   |    Rss:                   0 kB
Shared_Dirty:          0 kB                                                     
                        Shared_Dirty:          0 kB
Private_Dirty:         4 kB                                                     
                   |    Private_Dirty:         0 kB
                                                                                
                   >    7fc190000000-7fc198000000 rw-p 00000000 00:00 0 
                                                                                
                   >    Rss:              131072 kB
                                                                                
                   >    Shared_Dirty:          0 kB
                                                                                
                   >    Private_Dirty:    131072 kB
                                                                                
                   >    7fc198000000-7fc19c000000 rw-p 00000000 00:00 0 
                                                                                
                   >    Rss:               65536 kB
                                                                                
                   >    Shared_Dirty:          0 kB
                                                                                
                   >    Private_Dirty:     65536 kB
                                                                                
                   >    7fc19ec88000-7fc19ed88000 rw-s 00000000 00:1a 243       
                 /i915 (deleted)
                                                                                
                   >    Rss:                 716 kB
                                                                                
                   >    Shared_Dirty:          0 kB
                                                                                
                   >    Private_Dirty:       716 kB
7fc19ed88000-7fc19ed90000 rw-s 00000000 00:1a 799                        /i915 
(deleted)                7fc19ed88000-7fc19ed90000 rw-s 00000000 00:1a 799      
                  /i915 (deleted)
Rss:                  32 kB                                                     
                        Rss:                  32 kB
Shared_Dirty:          0 kB                                                     
                        Shared_Dirty:          0 kB
Private_Dirty:        32 kB                                                     
                        Private_Dirty:        32 kB
~~~

Left column is the 5-minute smaps, and the right column is the 12-hour
smaps.

Wirawan

** Attachment added: "snapshot of "ps faux""
   
https://bugs.launchpad.net/ubuntu/+source/vlc/+bug/1888558/+attachment/5398671/+files/vlc-vvv-usage-wirawan2-Sisters_M16.txt

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1888558

Title:
  VLC is using up to 2 GB of RAM just to play a regular 720px HD video

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/vlc/+bug/1888558/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to