diff options
author | Laku <Lakumakkara@users.noreply.github.com> | 2018-08-31 03:32:58 +0200 |
---|---|---|
committer | bunnei <bunneidev@gmail.com> | 2018-08-31 03:32:58 +0200 |
commit | 915ab81ec203d40e6f67d3cfa6e2e26599bec570 (patch) | |
tree | 1e74c1c52f86e89c3ddc9e166034f5b96b194760 /src/video_core/renderer_opengl | |
parent | Merge pull request #1200 from bunnei/improve-ipa (diff) | |
download | yuzu-915ab81ec203d40e6f67d3cfa6e2e26599bec570.tar yuzu-915ab81ec203d40e6f67d3cfa6e2e26599bec570.tar.gz yuzu-915ab81ec203d40e6f67d3cfa6e2e26599bec570.tar.bz2 yuzu-915ab81ec203d40e6f67d3cfa6e2e26599bec570.tar.lz yuzu-915ab81ec203d40e6f67d3cfa6e2e26599bec570.tar.xz yuzu-915ab81ec203d40e6f67d3cfa6e2e26599bec570.tar.zst yuzu-915ab81ec203d40e6f67d3cfa6e2e26599bec570.zip |
Diffstat (limited to 'src/video_core/renderer_opengl')
-rw-r--r-- | src/video_core/renderer_opengl/gl_shader_decompiler.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/video_core/renderer_opengl/gl_shader_decompiler.cpp b/src/video_core/renderer_opengl/gl_shader_decompiler.cpp index 7b6eb25a4..842bfa0b7 100644 --- a/src/video_core/renderer_opengl/gl_shader_decompiler.cpp +++ b/src/video_core/renderer_opengl/gl_shader_decompiler.cpp @@ -1363,6 +1363,15 @@ private: "((" + op_a + " << " + shift + ") + " + op_b + ')', 1, 1); break; } + case OpCode::Id::POPC_C: + case OpCode::Id::POPC_R: + case OpCode::Id::POPC_IMM: { + if (instr.popc.invert) { + op_b = "~(" + op_b + ')'; + } + regs.SetRegisterToInteger(instr.gpr0, true, 0, "bitCount(" + op_b + ')', 1, 1); + break; + } case OpCode::Id::SEL_C: case OpCode::Id::SEL_R: case OpCode::Id::SEL_IMM: { |