summaryrefslogtreecommitdiff
path: root/src/shader_recompiler/frontend/maxwell/translate_program.cpp
diff options
context:
space:
mode:
authorGravatar ReinUsesLisp2021-07-11 01:10:38 -0300
committerGravatar ameerj2021-07-22 21:51:40 -0400
commit2235a51b5d987cf8297211bb1778d75e6b794324 (patch)
tree41f8cf809753eecf774507069c1fbbc75b18af30 /src/shader_recompiler/frontend/maxwell/translate_program.cpp
parentrenderers: Disable async shader compilation (diff)
downloadyuzu-2235a51b5d987cf8297211bb1778d75e6b794324.tar.gz
yuzu-2235a51b5d987cf8297211bb1778d75e6b794324.tar.xz
yuzu-2235a51b5d987cf8297211bb1778d75e6b794324.zip
shader: Manually convert from array<u32> to bitset instead of using bit_cast
Diffstat (limited to 'src/shader_recompiler/frontend/maxwell/translate_program.cpp')
-rw-r--r--src/shader_recompiler/frontend/maxwell/translate_program.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/shader_recompiler/frontend/maxwell/translate_program.cpp b/src/shader_recompiler/frontend/maxwell/translate_program.cpp
index 2bb1d24a4..83c77967d 100644
--- a/src/shader_recompiler/frontend/maxwell/translate_program.cpp
+++ b/src/shader_recompiler/frontend/maxwell/translate_program.cpp
@@ -3,7 +3,6 @@
3// Refer to the license.txt file included. 3// Refer to the license.txt file included.
4 4
5#include <algorithm> 5#include <algorithm>
6#include <bit>
7#include <memory> 6#include <memory>
8#include <ranges> 7#include <ranges>
9#include <vector> 8#include <vector>
@@ -144,7 +143,9 @@ IR::Program TranslateProgram(ObjectPool<IR::Inst>& inst_pool, ObjectPool<IR::Blo
144 program.is_geometry_passthrough = sph.common0.geometry_passthrough != 0; 143 program.is_geometry_passthrough = sph.common0.geometry_passthrough != 0;
145 if (program.is_geometry_passthrough) { 144 if (program.is_geometry_passthrough) {
146 const auto& mask{env.GpPassthroughMask()}; 145 const auto& mask{env.GpPassthroughMask()};
147 program.info.passthrough.mask |= ~std::bit_cast<std::bitset<256>>(mask); 146 for (size_t i = 0; i < program.info.passthrough.mask.size(); ++i) {
147 program.info.passthrough.mask[i] = ((mask[i / 32] >> (i % 32)) & 1) == 0;
148 }
148 } 149 }
149 break; 150 break;
150 } 151 }