[Libav-user] Full memory release after file processing is completed.
Anton Kolhidov
Landgraf132 at yandex.ru
Thu Jul 25 16:34:33 EEST 2019
Hi everyone,
I am writing an application that handles many video files. I limit the
addition of new video files by the amount of consumed RAM. I'm having a
problem related to that after processing the video libav does not release
all using memory. I know that this is done to increase performance and then
this busy memory is used again. But when I process large files, RAM is busy
at 90% and this value doesn't decrease.
I reproduced this in the following example:
https://github.com/libav/libav/blob/master/doc/examples/decode_video.c
I tried using «Adress sanitizer» and valgrind. Adress sanitizer did not find
any errors. Valgrind showed ~ 3 GB of still reachable memory after the
application was shut down.
How can I reset / clear this buffer in libav?
I processed the same file several times. Here is a graph of memory
consumption.
<http://libav-users.943685.n4.nabble.com/file/t376201/RrPPSGq.png>
--
Sent from: http://libav-users.943685.n4.nabble.com/
More information about the Libav-user
mailing list