diff options
| author | 2018-09-02 10:44:13 -0400 | |
|---|---|---|
| committer | 2018-09-02 10:44:13 -0400 | |
| commit | 9c206fe94d306775801f16b0bba8517b72338e18 (patch) | |
| tree | c729135f498a9bb7636fca9dc63aa0478358734a /src/video_core | |
| parent | Merge pull request #1218 from ogniK5377/fmul-assert (diff) | |
| parent | Removed saturate assert (diff) | |
| download | yuzu-9c206fe94d306775801f16b0bba8517b72338e18.tar.gz yuzu-9c206fe94d306775801f16b0bba8517b72338e18.tar.xz yuzu-9c206fe94d306775801f16b0bba8517b72338e18.zip | |
Merge pull request #1216 from ogniK5377/ffma-assert
Added FFMA asserts and missing fields
Diffstat (limited to 'src/video_core')
| -rw-r--r-- | src/video_core/engines/shader_bytecode.h | 3 | ||||
| -rw-r--r-- | src/video_core/renderer_opengl/gl_shader_decompiler.cpp | 6 |
2 files changed, 9 insertions, 0 deletions
diff --git a/src/video_core/engines/shader_bytecode.h b/src/video_core/engines/shader_bytecode.h index c8052a612..663c1d4af 100644 --- a/src/video_core/engines/shader_bytecode.h +++ b/src/video_core/engines/shader_bytecode.h | |||
| @@ -403,8 +403,11 @@ union Instruction { | |||
| 403 | } flow; | 403 | } flow; |
| 404 | 404 | ||
| 405 | union { | 405 | union { |
| 406 | BitField<47, 1, u64> cc; | ||
| 406 | BitField<48, 1, u64> negate_b; | 407 | BitField<48, 1, u64> negate_b; |
| 407 | BitField<49, 1, u64> negate_c; | 408 | BitField<49, 1, u64> negate_c; |
| 409 | BitField<51, 2, u64> tab5980_1; | ||
| 410 | BitField<53, 2, u64> tab5980_0; | ||
| 408 | } ffma; | 411 | } ffma; |
| 409 | 412 | ||
| 410 | union { | 413 | union { |
diff --git a/src/video_core/renderer_opengl/gl_shader_decompiler.cpp b/src/video_core/renderer_opengl/gl_shader_decompiler.cpp index 866afc7b5..e7d581d2d 100644 --- a/src/video_core/renderer_opengl/gl_shader_decompiler.cpp +++ b/src/video_core/renderer_opengl/gl_shader_decompiler.cpp | |||
| @@ -1445,6 +1445,12 @@ private: | |||
| 1445 | std::string op_b = instr.ffma.negate_b ? "-" : ""; | 1445 | std::string op_b = instr.ffma.negate_b ? "-" : ""; |
| 1446 | std::string op_c = instr.ffma.negate_c ? "-" : ""; | 1446 | std::string op_c = instr.ffma.negate_c ? "-" : ""; |
| 1447 | 1447 | ||
| 1448 | ASSERT_MSG(instr.ffma.cc == 0, "FFMA cc not implemented"); | ||
| 1449 | ASSERT_MSG(instr.ffma.tab5980_0 == 1, "FFMA tab5980_0({}) not implemented", | ||
| 1450 | instr.ffma.tab5980_0.Value()); // Seems to be 1 by default based on SMO | ||
| 1451 | ASSERT_MSG(instr.ffma.tab5980_1 == 0, "FFMA tab5980_1({}) not implemented", | ||
| 1452 | instr.ffma.tab5980_1.Value()); | ||
| 1453 | |||
| 1448 | switch (opcode->GetId()) { | 1454 | switch (opcode->GetId()) { |
| 1449 | case OpCode::Id::FFMA_CR: { | 1455 | case OpCode::Id::FFMA_CR: { |
| 1450 | op_b += regs.GetUniform(instr.cbuf34.index, instr.cbuf34.offset, | 1456 | op_b += regs.GetUniform(instr.cbuf34.index, instr.cbuf34.offset, |