In my hello quad app I based off the howtovulkan tutorial, written in c and vulkan 1.3+, no window shows up, the process is oomkilled, and several errors occur:
Selected device: Intel(R) Arc™ B570 Graphics (BMG G21)
recreateSwapchain() call #1, windowSize=(1280,720)
[validation] vkCreateShaderModule(): pCreateInfo->pCode (spirv-val produced an error):
Invalid SPIR-V header.
Command to reproduce:
spirv-val <input.spv> --relax-block-layout --target-env vulkan1.3The Vulkan spec states: If pCode is a pointer to SPIR-V code, pCode must adhere to the validation rules described by the Validation Rules within a Module section of the SPIR-V Environment appendix ( docs vulkan org/spec/latest/chapters/shaders.html#VUID-VkShaderModuleCreateInfo-pCode-08737)
Killed ./build/vulkanapp
I am using these libraries on a gentoo linux box with kde plasma and wayland:
VMA
Volk
SDL
cglm
I highly suspect these issues:
my glsl code is bad (unlikely)
glslc is doing something wrong
quantum bit flips (nearly impossible)
my loop is allocating memory and not freeing 18.6 GiB of space
somehow my unfreed single malloc()'s are misbehaving
I have googled this exact problem, asked ai (claude/qwen), and read my code and makefile over
my source code is on github, tbhtyson/peranti