diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/video_core/shader/shader_jit_x64.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/video_core/shader/shader_jit_x64.cpp b/src/video_core/shader/shader_jit_x64.cpp index dffe051ef..d74b58d84 100644 --- a/src/video_core/shader/shader_jit_x64.cpp +++ b/src/video_core/shader/shader_jit_x64.cpp | |||
| @@ -741,7 +741,9 @@ void JitCompiler::Compile_Block(unsigned end) { | |||
| 741 | void JitCompiler::Compile_NextInstr(unsigned* offset) { | 741 | void JitCompiler::Compile_NextInstr(unsigned* offset) { |
| 742 | offset_ptr = offset; | 742 | offset_ptr = offset; |
| 743 | 743 | ||
| 744 | Instruction instr = *(Instruction*)&g_state.vs.program_code[(*offset_ptr)++]; | 744 | Instruction instr; |
| 745 | std::memcpy(&instr, &g_state.vs.program_code[(*offset_ptr)++], sizeof(Instruction)); | ||
| 746 | |||
| 745 | OpCode::Id opcode = instr.opcode.Value(); | 747 | OpCode::Id opcode = instr.opcode.Value(); |
| 746 | auto instr_func = instr_table[static_cast<unsigned>(opcode)]; | 748 | auto instr_func = instr_table[static_cast<unsigned>(opcode)]; |
| 747 | 749 | ||