diff --git a/src/scripting/vm/jit.cpp b/src/scripting/vm/jit.cpp index b24ac7920..032ff68d3 100644 --- a/src/scripting/vm/jit.cpp +++ b/src/scripting/vm/jit.cpp @@ -155,7 +155,6 @@ bool JitCompiler::CanJit(VMScriptFunction *sfunc) case OP_LCS_R: case OP_SS_R: case OP_IJMP: - case OP_CALL: // this one is implemented but crashes currently case OP_TAIL: case OP_TAIL_K: return false; diff --git a/src/scripting/vm/jit_flow.cpp b/src/scripting/vm/jit_flow.cpp index 708bed744..72677f846 100644 --- a/src/scripting/vm/jit_flow.cpp +++ b/src/scripting/vm/jit_flow.cpp @@ -36,15 +36,14 @@ void JitCompiler::EmitVTBL() EmitThrowException(X_READ_NIL); cc.bind(notnull); - auto result = cc.newInt32(); typedef VMFunction*(*FuncPtr)(DObject*, int); auto call = cc.call(ToMemAddress(reinterpret_cast(static_cast([](DObject *o, int c) -> VMFunction* { auto p = o->GetClass(); assert(c < (int)p->Virtuals.Size()); return p->Virtuals[c]; }))), asmjit::FuncSignature2()); - call->setRet(0, result); - call->setArg(0, regA[A]); + call->setRet(0, regA[A]); + call->setArg(0, regA[B]); call->setArg(1, asmjit::Imm(C)); }