Re: [FFmpeg-devel] [PATCH 3/3] avfilter/formats: Avoid reallocations for video in ff_all_formats()

2021-09-26 Thread Nicolas George
Andreas Rheinhardt (12021-09-26): > Up until now, the list of pixfmts is reallocated every time an entry > is added to it; there are currently 196 pixel formats, so this matters: > It causes 5541704 calls to av_realloc_array() in a typical FATE run, > which is the majority for said function

[FFmpeg-devel] [PATCH 3/3] avfilter/formats: Avoid reallocations for video in ff_all_formats()

2021-09-25 Thread Andreas Rheinhardt
Up until now, the list of pixfmts is reallocated every time an entry is added to it; there are currently 196 pixel formats, so this matters: It causes 5541704 calls to av_realloc_array() in a typical FATE run, which is the majority for said function (8095768 calls) and even a large chunk of the