From 5bb9c644ec17a298d901152e9a8e10f8d08c2ee3 Mon Sep 17 00:00:00 2001 From: Paul Thomson Date: Sat, 3 Aug 2019 16:12:59 +0100 Subject: Add option to disable SPIR-V validation (#615) This CL adds a command inline flag --disable-spirv-val which will skip the validation of the generated SPIR-V binary. --- src/shader_compiler.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/shader_compiler.h') diff --git a/src/shader_compiler.h b/src/shader_compiler.h index f9566e5..bf5fc49 100644 --- a/src/shader_compiler.h +++ b/src/shader_compiler.h @@ -30,7 +30,7 @@ namespace amber { class ShaderCompiler { public: ShaderCompiler(); - explicit ShaderCompiler(const std::string& env); + ShaderCompiler(const std::string& env, bool disable_spirv_validation); ~ShaderCompiler(); /// Returns a result code and a compilation of the given shader. @@ -53,6 +53,7 @@ class ShaderCompiler { std::vector* result) const; std::string spv_env_; + bool disable_spirv_validation_ = false; }; // Parses the SPIR-V environment string, and returns the corresponding -- cgit v1.2.3