-
STACK_ARRAY() is used in a lot of places. When games are running we see STACK_ARRAY() arrays being used all the time: each queue submission uses 6, WaitSemaphores and syncobj waiting also uses them: they're constantly present in Vulkan runtime. There's no need for STACK_ARRAY()'s stack array to be initialized, callers cannot not depend on it. If the number of elements is greater than STACK_ARRAY_SIZE, then STACK_ARRAY() will just malloc() the array and return it not initialized: anybody depending of zero-initialization is going to break when the array is big. The reason why we're zero-intializing STACK_ARRAY()'s stack array is to silence -Wmaybe-uninitialized warnings: see commit d7957df3 ("vulkan: fix uninitialized variables"). I don't think that commit is the ideal way to deal with the problem, so this patch proposes a better solution. The problem here is that zero-initializing it adds code we don't need for every single caller. STACK_ARRA...