mirror of
https://github.com/N64Recomp/N64Recomp.git
synced 2026-05-15 15:39:50 -05:00
Found a third emit-non-compilable-code path during Pokemon Stadium runner build: print_branch lambda (line 371) checks for tail-call candidates when the branch target is outside the function, prints a warning if not found — then falls through to emit `goto L_<branch_target>` to a label that doesn't exist in the generated function. Linker compiles fail with "use of undeclared label L_XXXXXXXX". Fixed by emitting the same recomp_unhandled_branch runtime call as the other tolerant-emit paths, plus an early return so the fall- through to emit_goto doesn't run. Also exposes recomp_unhandled_* declarations in include/recomp.h (after the existing recomp_context definition + recomp_syscall_handler decl) so generated C compiles cleanly without consumer-side header patches. 171 → ~600+ tolerant-emit warnings on Pokemon Stadium pass; full build pipeline now produces a linked PokemonStadiumRecomp.exe that loads librecomp/ultramodern and runs cleanly to a "link-only entry" message. Real boot still needs runtime wiring (renderer, scheduler, init). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| recompiler | ||
| recomp.h | ||