[Bf-blender-cvs] [1cdcfa3a89e] temp-vulkan-shader: Enable performance optimizations.
Jeroen Bakker
noreply at git.blender.org
Tue Dec 6 10:09:35 CET 2022
Commit: 1cdcfa3a89e4c1c9557a7de87208d626f5411147
Author: Jeroen Bakker
Date: Tue Dec 6 10:09:26 2022 +0100
Branches: temp-vulkan-shader
https://developer.blender.org/rB1cdcfa3a89e4c1c9557a7de87208d626f5411147
Enable performance optimizations.
===================================================================
M source/blender/gpu/vulkan/vk_shader.cc
===================================================================
diff --git a/source/blender/gpu/vulkan/vk_shader.cc b/source/blender/gpu/vulkan/vk_shader.cc
index 7cdeca228bb..c4dfbc4b19d 100644
--- a/source/blender/gpu/vulkan/vk_shader.cc
+++ b/source/blender/gpu/vulkan/vk_shader.cc
@@ -530,6 +530,7 @@ Vector<uint32_t> VKShader::compile_glsl_to_spirv(Span<const char *> sources,
VKBackend &backend = static_cast<VKBackend &>(*VKBackend::get());
shaderc::Compiler &compiler = backend.get_shaderc_compiler();
shaderc::CompileOptions options;
+ options.SetOptimizationLevel(shaderc_optimization_level_performance);
shaderc::SpvCompilationResult module = compiler.CompileGlslToSpv(
combined_sources, stage, name, options);
More information about the Bf-blender-cvs
mailing list