| 1428 | } |
| 1429 | |
| 1430 | void N64Recomp::LiveGenerator::emit_function_call(const Context&, size_t function_index) const { |
| 1431 | // Load rdram and ctx into R0 and R1. |
| 1432 | sljit_emit_op2(compiler, SLJIT_ADD, SLJIT_R0, 0, Registers::rdram, 0, SLJIT_IMM, rdram_offset); |
| 1433 | sljit_emit_op1(compiler, SLJIT_MOV, SLJIT_R1, 0, Registers::ctx, 0); |
| 1434 | // Call the function and save the jump to set its label later on. |
| 1435 | sljit_jump* call_jump = sljit_emit_call(compiler, SLJIT_CALL, SLJIT_ARGS2V(P, P)); |
| 1436 | context->inner_calls.emplace_back(InnerCall{ .target_func_index = function_index, .jump = call_jump }); |
| 1437 | } |
| 1438 | |
| 1439 | void N64Recomp::LiveGenerator::emit_named_function_call(const std::string& function_name) const { |
| 1440 | // The live recompiler can't call functions by name. This is only used for statics, so it's not an issue. |
nothing calls this directly
no outgoing calls
no test coverage detected