[Libva] libva memory leak

ebsi4711 ebsi4711 at gmail.com
Tue Jun 7 08:38:36 PDT 2011


Hi,

it looks like libva is leaking memory, I played around with my xine vaapi
implementation and mplayer. With both valgrind produces the following output
:

==17727== Invalid write of size 4
==17727==    at 0x15FD212A: intel_batchbuffer_emit_dword (in
/usr/lib/dri/i965_drv_video.so)
==17727==    by 0x15FE3BFE: i965_avc_bsd_pipeline (in
/usr/lib/dri/i965_drv_video.so)
==17727==    by 0x15FD693F: i965_media_h264_states_setup (in
/usr/lib/dri/i965_drv_video.so)
==17727==    by 0x15FD4817: i965_media_decode_picture (in
/usr/lib/dri/i965_drv_video.so)
==17727==    by 0x15FE0AEE: i965_EndPicture (in
/usr/lib/dri/i965_drv_video.so)
==17727==    by 0xBF5FA0F: vaEndPicture (in /usr/lib/libva.so.1.0.13)
==17727==    by 0xB42EE6: ff_vaapi_common_end_frame (in /usr/bin/mplayer)
==17727==    by 0x867139: ??? (in /usr/bin/mplayer)
==17727==    by 0x87484C: ??? (in /usr/bin/mplayer)
==17727==    by 0x9FF31F: avcodec_decode_video2 (in /usr/bin/mplayer)
==17727==    by 0x664260: ??? (in /usr/bin/mplayer)
==17727==    by 0x5699CA: decode_video (in /usr/bin/mplayer)
==17727==  Address 0x7f7caa73e230 is not stack'd, malloc'd or (recently)
free'd
==17727==
==17727== Invalid read of size 1
==17727==    at 0x15FE2393: i965_avc_bsd_get_slice_bit_offset (in
/usr/lib/dri/i965_drv_video.so)
==17727==    by 0x15FE2767: i965_avc_bsd_object (in
/usr/lib/dri/i965_drv_video.so)
==17727==    by 0x15FE3C2A: i965_avc_bsd_pipeline (in
/usr/lib/dri/i965_drv_video.so)
==17727==    by 0x15FD693F: i965_media_h264_states_setup (in
/usr/lib/dri/i965_drv_video.so)
==17727==    by 0x15FD4817: i965_media_decode_picture (in
/usr/lib/dri/i965_drv_video.so)
==17727==    by 0x15FE0AEE: i965_EndPicture (in
/usr/lib/dri/i965_drv_video.so)
==17727==    by 0xBF5FA0F: vaEndPicture (in /usr/lib/libva.so.1.0.13)
==17727==    by 0xB42EE6: ff_vaapi_common_end_frame (in /usr/bin/mplayer)
==17727==    by 0x867139: ??? (in /usr/bin/mplayer)
==17727==    by 0x87484C: ??? (in /usr/bin/mplayer)
==17727==    by 0x9FF31F: avcodec_decode_video2 (in /usr/bin/mplayer)
==17727==    by 0x664260: ??? (in /usr/bin/mplayer)
==17727==  Address 0x7f7caa73d000 is not stack'd, malloc'd or (recently)
free'd

--17727-- REDIR: 0xd159710 (memalign) redirected to 0x4c23880 (memalign)
==17727== Invalid write of size 8
==17727==    at 0x15FD9975: i965_render_vs_unit (in
/usr/lib/dri/i965_drv_video.so)
==17727==    by 0x15FDBEAA: intel_render_put_surface (in
/usr/lib/dri/i965_drv_video.so)
==17727==    by 0x15FDE676: i965_PutSurface (in
/usr/lib/dri/i965_drv_video.so)
==17727==    by 0x50FB3C: ??? (in /usr/bin/mplayer)
==17727==    by 0x510CF1: ??? (in /usr/bin/mplayer)
==17727==    by 0x4DEE62: main (in /usr/bin/mplayer)
==17727==  Address 0x7f7caa5c3000 is not stack'd, malloc'd or (recently)
free'd
==17727==
==17727== Invalid write of size 8
==17727==    at 0x15FD997C: i965_render_vs_unit (in
/usr/lib/dri/i965_drv_video.so)
==17727==    by 0x15FDBEAA: intel_render_put_surface (in
/usr/lib/dri/i965_drv_video.so)
==17727==    by 0x15FDE676: i965_PutSurface (in
/usr/lib/dri/i965_drv_video.so)
==17727==    by 0x50FB3C: ??? (in /usr/bin/mplayer)
==17727==    by 0x510CF1: ??? (in /usr/bin/mplayer)
==17727==    by 0x4DEE62: main (in /usr/bin/mplayer)
==17727==  Address 0x7f7caa5c3008 is not stack'd, malloc'd or (recently)
free'd

The memory usage in mplayer and xine is growing and not freed. Also the cpu
usage is going up in both implementations.

lg

Ed
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/libva/attachments/20110607/316ea346/attachment-0001.html>


More information about the Libva mailing list