Implement CallHostFunction
This commit is contained in:
parent
79ff9401f3
commit
58a1e4cc63
1 changed files with 5 additions and 4 deletions
|
@ -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<>
|
||||||
|
|
Loading…
Reference in a new issue