Skip to content

vulkan: Fix weak symbol emulation when compiling with MSVC

Boris Brezillon requested to merge bbrezillon/mesa:vk-ms-entrypoint into main

Mapping unimplemented entrypoints to a global function pointer variable initialized to NULL is a bit cumbersome, and actually led to a bug in the vk_xxx_dispatch_table_from_entrypoints() template: the !override case didn't have the right check on the source table entries. Instead of fixing that case, let's simplify the logic by creating a stub function and making the alternatename pragma point to this stub. This way we get rid of all those uneeded xxx_Null symbols/variables and simplify the tests in vk_xxxx_dispatch_table_from_entrypoints().

Cc: mesa-stable Fixes: 98c622a9 ("vulkan: Update dispatch table gen for Windows") Signed-off-by: Boris Brezillon boris.brezillon@collabora.com

Replaces !13344 (closed)

/cc @jpark37 @jekstrand

Merge request reports