[FFmpeg-trac] #7943(undetermined:new): Ffmpeg QSV backend uses >2x more GPU memory compared to VAAPI or MSDK

FFmpeg trac at avcodec.org
Fri Oct 18 11:02:57 EEST 2019

#7943: Ffmpeg QSV backend uses >2x more GPU memory compared to VAAPI or MSDK
             Reporter:  eero-t       |                    Owner:
                 Type:  defect       |                   Status:  new
             Priority:  normal       |                Component:
                                     |  undetermined
              Version:  git-master   |               Resolution:
             Keywords:               |               Blocked By:
             Blocking:               |  Reproduced by developer:  0
Analyzed by developer:  0            |

Comment (by fulinjie):

 Another input:
 FFmpeg qsv sets initial_pool_size to a larger value (64) compared to

 which make sure there is enough memory in the pool for allocation.


 If you set the initial_pool_size to a relatively small value, for example:
 frames_ctx->initial_pool_size = 22 + s->extra_hw_frames;

 Similar GPU memory occupation could be obeserved:

 ffmpeg: 321 objects, 1179193344 bytes

 However, a small initial_pool_size may lead to some unexpected errors

 [hevc_qsv @ 0x55febd948300] get_buffer() failed
 Error while decoding stream #0:0: Cannot allocate memory

Ticket URL: <https://trac.ffmpeg.org/ticket/7943#comment:3>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker

More information about the FFmpeg-trac mailing list