summaryrefslogtreecommitdiffstats
path: root/src/shader_recompiler/ir_opt/collect_shader_info_pass.cpp
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/shader_recompiler/ir_opt/collect_shader_info_pass.cpp14
1 files changed, 4 insertions, 10 deletions
diff --git a/src/shader_recompiler/ir_opt/collect_shader_info_pass.cpp b/src/shader_recompiler/ir_opt/collect_shader_info_pass.cpp
index 0b2c60842..7cff8ecdc 100644
--- a/src/shader_recompiler/ir_opt/collect_shader_info_pass.cpp
+++ b/src/shader_recompiler/ir_opt/collect_shader_info_pass.cpp
@@ -1,6 +1,5 @@
-// Copyright 2021 yuzu Emulator Project
-// Licensed under GPLv2 or any later version
-// Refer to the license.txt file included.
+// SPDX-FileCopyrightText: Copyright 2021 yuzu Emulator Project
+// SPDX-License-Identifier: GPL-2.0-or-later
#include "common/alignment.h"
#include "shader_recompiler/environment.h"
@@ -32,13 +31,8 @@ void AddConstantBufferDescriptor(Info& info, u32 index, u32 count) {
void AddRegisterIndexedLdc(Info& info) {
info.uses_cbuf_indirect = true;
- // The shader can use any possible constant buffer
- info.constant_buffer_mask = (1 << Info::MAX_CBUFS) - 1;
-
- auto& cbufs{info.constant_buffer_descriptors};
- cbufs.clear();
- for (u32 i = 0; i < Info::MAX_CBUFS; i++) {
- cbufs.push_back(ConstantBufferDescriptor{.index = i, .count = 1});
+ for (u32 i = 0; i < Info::MAX_INDIRECT_CBUFS; i++) {
+ AddConstantBufferDescriptor(info, i, 1);
// The shader can use any possible access size
info.constant_buffer_used_sizes[i] = 0x10'000;