diff options
| author | 2021-04-04 02:31:09 -0300 | |
|---|---|---|
| committer | 2021-07-22 21:51:26 -0400 | |
| commit | 3f594dd86bd1ee1b178109132482c7d6b43e66dd (patch) | |
| tree | 7de68eba744644121f3409f2de8c2e7a0bd5c125 /src/shader_recompiler/backend/spirv/emit_context.cpp | |
| parent | vk_compute_pass: Fix compute passes (diff) | |
| download | yuzu-3f594dd86bd1ee1b178109132482c7d6b43e66dd.tar.gz yuzu-3f594dd86bd1ee1b178109132482c7d6b43e66dd.tar.xz yuzu-3f594dd86bd1ee1b178109132482c7d6b43e66dd.zip | |
shader: Reimplement GetCbufU64 as GetCbufU32x2
It may generate better code on some compilers and it's easier to handle.
Diffstat (limited to 'src/shader_recompiler/backend/spirv/emit_context.cpp')
| -rw-r--r-- | src/shader_recompiler/backend/spirv/emit_context.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/shader_recompiler/backend/spirv/emit_context.cpp b/src/shader_recompiler/backend/spirv/emit_context.cpp index 32f679f2a..e70b78a28 100644 --- a/src/shader_recompiler/backend/spirv/emit_context.cpp +++ b/src/shader_recompiler/backend/spirv/emit_context.cpp | |||
| @@ -308,8 +308,8 @@ void EmitContext::DefineConstantBuffers(const Info& info, u32& binding) { | |||
| 308 | if (True(info.used_constant_buffer_types & IR::Type::F32)) { | 308 | if (True(info.used_constant_buffer_types & IR::Type::F32)) { |
| 309 | DefineConstantBuffers(info, &UniformDefinitions::F32, binding, F32[1], 'f', sizeof(f32)); | 309 | DefineConstantBuffers(info, &UniformDefinitions::F32, binding, F32[1], 'f', sizeof(f32)); |
| 310 | } | 310 | } |
| 311 | if (True(info.used_constant_buffer_types & IR::Type::U64)) { | 311 | if (True(info.used_constant_buffer_types & IR::Type::U32x2)) { |
| 312 | DefineConstantBuffers(info, &UniformDefinitions::U64, binding, U64, 'u', sizeof(u64)); | 312 | DefineConstantBuffers(info, &UniformDefinitions::U32x2, binding, U32[2], 'u', sizeof(u64)); |
| 313 | } | 313 | } |
| 314 | for (const ConstantBufferDescriptor& desc : info.constant_buffer_descriptors) { | 314 | for (const ConstantBufferDescriptor& desc : info.constant_buffer_descriptors) { |
| 315 | binding += desc.count; | 315 | binding += desc.count; |