Restore ability to call static functions by name in C generator

This commit is contained in:
Mr-Wiseguy 2024-12-29 19:52:14 -05:00
parent f09587bf1f
commit 8c89f01df6
5 changed files with 19 additions and 3 deletions

View file

@ -1375,6 +1375,12 @@ void N64Recomp::LiveGenerator::emit_function_call(const Context&, size_t functio
context->inner_calls.emplace_back(InnerCall{ .target_func_index = function_index, .jump = call_jump });
}
void N64Recomp::LiveGenerator::emit_named_function_call(const std::string& function_name) const {
// The live recompiler can't call functions by name. This is only used for statics, so it's not an issue.
assert(false);
errored = true;
}
void N64Recomp::LiveGenerator::emit_goto(const std::string& target) const {
sljit_jump* jump = sljit_emit_jump(compiler, SLJIT_JUMP);
// Check if the label already exists.