diff options
author | Fernando Sahmkow <fsahmkow27@gmail.com> | 2021-11-17 04:19:29 +0100 |
---|---|---|
committer | Fernando Sahmkow <fsahmkow27@gmail.com> | 2022-01-04 02:39:00 +0100 |
commit | f58ee3f15f7427a8b834286384931bcf821ed771 (patch) | |
tree | 1ef8367f64cbee6220c4e5600249697e5cd8e826 /src/video_core/renderer_vulkan/vk_pipeline_cache.cpp | |
parent | Merge pull request #7648 from bunnei/thread-pinning (diff) | |
download | yuzu-f58ee3f15f7427a8b834286384931bcf821ed771.tar yuzu-f58ee3f15f7427a8b834286384931bcf821ed771.tar.gz yuzu-f58ee3f15f7427a8b834286384931bcf821ed771.tar.bz2 yuzu-f58ee3f15f7427a8b834286384931bcf821ed771.tar.lz yuzu-f58ee3f15f7427a8b834286384931bcf821ed771.tar.xz yuzu-f58ee3f15f7427a8b834286384931bcf821ed771.tar.zst yuzu-f58ee3f15f7427a8b834286384931bcf821ed771.zip |
Diffstat (limited to 'src/video_core/renderer_vulkan/vk_pipeline_cache.cpp')
-rw-r--r-- | src/video_core/renderer_vulkan/vk_pipeline_cache.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/video_core/renderer_vulkan/vk_pipeline_cache.cpp b/src/video_core/renderer_vulkan/vk_pipeline_cache.cpp index 2728353c8..a633b73e5 100644 --- a/src/video_core/renderer_vulkan/vk_pipeline_cache.cpp +++ b/src/video_core/renderer_vulkan/vk_pipeline_cache.cpp @@ -517,6 +517,9 @@ std::unique_ptr<GraphicsPipeline> PipelineCache::CreateGraphicsPipeline( const u32 cfg_offset{static_cast<u32>(env.StartAddress() + sizeof(Shader::ProgramHeader))}; Shader::Maxwell::Flow::CFG cfg(env, pools.flow_block, cfg_offset, index == 0); + if (Settings::values.dump_shaders) { + env.Dump(key.unique_hashes[index]); + } if (!uses_vertex_a || index != 1) { // Normal path programs[index] = TranslateProgram(pools.inst, pools.block, env, cfg, host_info); @@ -613,6 +616,12 @@ std::unique_ptr<ComputePipeline> PipelineCache::CreateComputePipeline( LOG_INFO(Render_Vulkan, "0x{:016x}", key.Hash()); Shader::Maxwell::Flow::CFG cfg{env, pools.flow_block, env.StartAddress()}; + + // Dump it before error. + if (Settings::values.dump_shaders) { + env.Dump(key.Hash()); + } + auto program{TranslateProgram(pools.inst, pools.block, env, cfg, host_info)}; const std::vector<u32> code{EmitSPIRV(profile, program)}; device.SaveShader(code); |