mirror of
https://git.eden-emu.dev/eden-emu/eden
synced 2026-11-02 00:51:58 +01:00
[TEST] Prune on passthrough stores
This commit is contained in:
parent
b0a01ca629
commit
faacc62b10
4 changed files with 58 additions and 2 deletions
|
|
@ -45,6 +45,7 @@ using Shader::Backend::SPIRV::EmitSPIRV;
|
|||
using Shader::Maxwell::ConvertLegacyToGeneric;
|
||||
using Shader::Maxwell::GenerateGeometryPassthrough;
|
||||
using Shader::Maxwell::MergeDualVertexPrograms;
|
||||
using Shader::Maxwell::PrunePassthroughStores;
|
||||
using Shader::Maxwell::TranslateProgram;
|
||||
using VideoCommon::ComputeEnvironment;
|
||||
using VideoCommon::FileEnvironment;
|
||||
|
|
@ -54,7 +55,7 @@ using VideoCommon::LoadPipelines;
|
|||
using VideoCommon::SerializePipeline;
|
||||
using Context = ShaderContext::Context;
|
||||
|
||||
constexpr u32 CACHE_VERSION = 17;
|
||||
constexpr u32 CACHE_VERSION = 18;
|
||||
|
||||
template <typename Container>
|
||||
auto MakeSpan(Container& container) {
|
||||
|
|
@ -537,6 +538,9 @@ std::unique_ptr<GraphicsPipeline> ShaderCache::CreateGraphicsPipeline(
|
|||
const size_t stage_index{index - 1};
|
||||
infos[stage_index] = &program.info;
|
||||
|
||||
if (previous_program) {
|
||||
PrunePassthroughStores(program, previous_program->info.stores);
|
||||
}
|
||||
const auto runtime_info = MakeRuntimeInfo(key, program, previous_program, glasm_use_storage_buffers, use_glasm);
|
||||
switch (::Settings::values.renderer_backend.GetValue()) {
|
||||
case Settings::RendererBackend::OpenGL_GLSL:
|
||||
|
|
|
|||
|
|
@ -56,13 +56,14 @@ using Shader::Backend::SPIRV::EmitSPIRV;
|
|||
using Shader::Maxwell::ConvertLegacyToGeneric;
|
||||
using Shader::Maxwell::GenerateGeometryPassthrough;
|
||||
using Shader::Maxwell::MergeDualVertexPrograms;
|
||||
using Shader::Maxwell::PrunePassthroughStores;
|
||||
using Shader::Maxwell::TranslateProgram;
|
||||
using VideoCommon::ComputeEnvironment;
|
||||
using VideoCommon::FileEnvironment;
|
||||
using VideoCommon::GenericEnvironment;
|
||||
using VideoCommon::GraphicsEnvironment;
|
||||
|
||||
constexpr u32 CACHE_VERSION = 20;
|
||||
constexpr u32 CACHE_VERSION = 21;
|
||||
constexpr size_t VULKAN_CACHE_FLUSH_PIPELINES = 128;
|
||||
constexpr size_t VULKAN_CACHE_FLUSH_MIN_SECONDS = 30;
|
||||
constexpr std::array<char, 8> VULKAN_CACHE_MAGIC_NUMBER{'y', 'u', 'z', 'u', 'v', 'k', 'c', 'h'};
|
||||
|
|
@ -838,6 +839,9 @@ std::unique_ptr<GraphicsPipeline> PipelineCache::CreateGraphicsPipeline(
|
|||
const size_t stage_index{index - 1};
|
||||
infos[stage_index] = &program.info;
|
||||
|
||||
if (previous_stage) {
|
||||
PrunePassthroughStores(program, previous_stage->info.stores);
|
||||
}
|
||||
const auto runtime_info{MakeRuntimeInfo(programs, key, program, previous_stage, device)};
|
||||
ConvertLegacyToGeneric(program, runtime_info);
|
||||
const std::vector<u32> code{EmitSPIRV(profile, runtime_info, program, binding)};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue