-
Validate the SPIR-V code in debug builds · 45510ad8Nicolas Capens authored
https://www.khronos.org/registry/vulkan/specs/1.2-extensions/man/html/VkShaderModuleCreateInfo.html states that the "code must adhere to the validation rules described by the Validation Rules within a Module section of the SPIR-V Environment appendix" This makes it the application's responsibility to only pass valid SPIR-V code to vkCreateShaderModule. However, improperly validated code may cause bugs which are hard to root cause, so validate in our implementation as well in debug builds. This can also help with fuzzing efforts. Bug: b/158228522 Change-Id: Ib4f41fa70a021fb902e1f8504005b87c92286942 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/45569Tested-by:
Nicolas Capens <nicolascapens@google.com> Kokoro-Result: kokoro <noreply+kokoro@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com>
45510ad8
×