[FFmpeg-devel] [PATCH 3/3] avcodec/vulkan_decode: Un-sparse extensions table

Andreas Rheinhardt andreas.rheinhardt at outlook.com
Thu Mar 7 02:36:00 EET 2024


Lynne:
> Mar 3, 2024, 12:35 by andreas.rheinhardt at outlook.com:
> 
>> Only three of the 226 (== AV_CODEC_ID_AV1) entries
>> have been used. Unsparsing this table is especially
>> important given that this array lives in .data.rel.ro.
>>
>> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt at outlook.com>
>> ---
>> Instead of parallel tables, one could also merge VkCodecMap and
>> VkExtensionProperties (i.e. putting one of the latter inside
>> the former) if preferred.
>>
>> libavcodec/vulkan_decode.c | 28 ++++++++++++++++++++++------
>> 1 file changed, 22 insertions(+), 6 deletions(-)
>>
> 
> LGTM on commits 1 and 3.
> Would you mind keeping the designated initializers from
> commit 2 but still keeping it into vulkan_video.c?
> Would save on needing to deduplicate it in the future.

I still don't know what you mean by "deduplicating" them in the future.
Anyway, I have now implemented the approach outlined in the comment
above: https://ffmpeg.org/pipermail/ffmpeg-devel/2024-March/322893.html

- Andreas



More information about the ffmpeg-devel mailing list