I'm working on a UE4 project. By default UE4 compile its shader to spirv binary by hlslcc + glslang, but in this way the generated spirv shader is suboptimal so I want to use shaderconductor(DXC) to compile hlsl directly to spirv (just like what UE5 does: Unreal Engine 5.0 Release Notes | Unreal Engine 5.0 Documentation)
After I use DXC, the project works pretty well on adreno devices, but it will crash on mali deviecs. I have tried these devices, the all failed to create pipeline (both compute ppl and graphics ppl) with VK_ERROR_INITIALIZATION_FAILED:
The khr spec states that create pipeline should only return the following errors:
and also adreno devices works well, so I guess this might be mali driver bugs.
I have no clue what's goes wrong with generated spirv binary and it seems I can't get enough error information from vulkan, so I need to ask help from mali experts.
I can send you the apk that can produce the failure so if you are interested please leave me a email address. Thanks in advance!
Thanks christian! Yes I'm aware the UE5 has extra pass to strip these extension and debug symbols, but I thought it's only used for mali offline compiler because the variable bStripReflect is defined by SupportsOfflineCompiler. Also I thought the "online" compiler in the driver can silently skip this unsupported extension because I saw the extension spec says "This has no semantic impact": SPIRV-Registry/SPV_GOOGLE_user_type.asciidoc at main · KhronosGroup/SPIRV-Registry (github.com) So it turns out I might be wrong. I can try add similiar pass in UE4 and check if it can fix the problem. I will reach you once I have some progress. Thanks for your important insights again!