Implement CallHostFunction

This commit is contained in:
Macdu 2022-10-16 22:50:07 +02:00 committed by merry
parent 79ff9401f3
commit 58a1e4cc63

View file

@ -38,10 +38,11 @@ void EmitIR<IR::Opcode::Breakpoint>(oaknut::CodeGenerator& code, EmitContext&, I
template<> template<>
void EmitIR<IR::Opcode::CallHostFunction>(oaknut::CodeGenerator& code, EmitContext& ctx, IR::Inst* inst) { void EmitIR<IR::Opcode::CallHostFunction>(oaknut::CodeGenerator& code, EmitContext& ctx, IR::Inst* inst) {
(void)code; auto args = ctx.reg_alloc.GetArgumentInfo(inst);
(void)ctx;
(void)inst; ctx.reg_alloc.PrepareForCall(nullptr, args[1], args[2], args[3]);
ASSERT_FALSE("Unimplemented"); code.MOV(Xscratch0, args[0].GetImmediateU64());
code.BLR(Xscratch0);
} }
template<> template<>