diff options
| author | 2019-05-12 16:38:51 -0500 | |
|---|---|---|
| committer | 2019-05-12 16:38:51 -0500 | |
| commit | 9ef45f00bf452170c95255f5a3a566d5af91c102 (patch) | |
| tree | ee78395d11dbd3e6e97af07190503200e84e77e9 /src/video_core/macro_interpreter.cpp | |
| parent | Merge pull request #2437 from lioncash/audctl (diff) | |
| download | yuzu-9ef45f00bf452170c95255f5a3a566d5af91c102.tar.gz yuzu-9ef45f00bf452170c95255f5a3a566d5af91c102.tar.xz yuzu-9ef45f00bf452170c95255f5a3a566d5af91c102.zip | |
GPU/MMEInterpreter: Ignore the 'exit' flag when it's executed inside a delay slot.
It seems instructions marked with the 'exit' flag will not cause an exit when executed within a delay slot.
This was hwtested by fincs.
Diffstat (limited to 'src/video_core/macro_interpreter.cpp')
| -rw-r--r-- | src/video_core/macro_interpreter.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/video_core/macro_interpreter.cpp b/src/video_core/macro_interpreter.cpp index 524d9ea5a..fbea107ca 100644 --- a/src/video_core/macro_interpreter.cpp +++ b/src/video_core/macro_interpreter.cpp | |||
| @@ -118,10 +118,10 @@ bool MacroInterpreter::Step(u32 offset, bool is_delay_slot) { | |||
| 118 | static_cast<u32>(opcode.operation.Value())); | 118 | static_cast<u32>(opcode.operation.Value())); |
| 119 | } | 119 | } |
| 120 | 120 | ||
| 121 | if (opcode.is_exit) { | 121 | // An instruction with the Exit flag will not actually |
| 122 | // cause an exit if it's executed inside a delay slot. | ||
| 123 | if (opcode.is_exit && !is_delay_slot) { | ||
| 122 | // Exit has a delay slot, execute the next instruction | 124 | // Exit has a delay slot, execute the next instruction |
| 123 | // Note: Executing an exit during a branch delay slot will cause the instruction at the | ||
| 124 | // branch target to be executed before exiting. | ||
| 125 | Step(offset, true); | 125 | Step(offset, true); |
| 126 | return false; | 126 | return false; |
| 127 | } | 127 | } |