From a8f8d8b65929e12ad663aecd59a5b86702d14b28 Mon Sep 17 00:00:00 2001 From: Magnus Norddahl Date: Fri, 15 May 2020 19:51:58 +0200 Subject: [PATCH] Successfully compile and run StatusScreen.drawNum with the new JIT --- src/common/scripting/jit/jit_flow.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/common/scripting/jit/jit_flow.cpp b/src/common/scripting/jit/jit_flow.cpp index c3cc66f7de..6cba24f464 100644 --- a/src/common/scripting/jit/jit_flow.cpp +++ b/src/common/scripting/jit/jit_flow.cpp @@ -87,7 +87,7 @@ void JitCompiler::EmitRET() cc.CreateCondBr(cc.CreateICmpSLE(ConstValueD(retnum), numret), ifbb, endifbb); cc.SetInsertPoint(ifbb); - IRValue* location = OffsetPtr(ret, retnum * sizeof(VMReturn)); + IRValue* location = Load(ToInt8PtrPtr(ret, retnum * sizeof(VMReturn))); int regtype = B; int regnum = C; @@ -185,7 +185,7 @@ void JitCompiler::EmitRETI() cc.CreateCondBr(cc.CreateICmpSLE(ConstValueD(retnum), numret), ifbb, endifbb); cc.SetInsertPoint(ifbb); - IRValue* location = OffsetPtr(ret, retnum * sizeof(VMReturn)); + IRValue* location = Load(ToInt8PtrPtr(ret, retnum * sizeof(VMReturn))); Store(ConstValueD(BCs), ToInt32Ptr(location)); if (a & RET_FINAL)