• I Cast Fist@programming.dev
    link
    fedilink
    English
    arrow-up
    0
    ·
    7 months ago

    Ok, any info on how that’s being done? It sure sounds like Wiseguy figured how to compile the code that was meant for the specific VR4300 (RISC) N64’s CPU for typical x86-64 architecture

    • bruhduh@lemmy.world
      link
      fedilink
      English
      arrow-up
      0
      ·
      edit-2
      7 months ago

      Apple Rosetta 2 technically recompiles code from x86 to arm too in jit and sometimes aot, also there’s box86/64 open source project, only difference between example I’ve said and OP is recompilation actually saves all results and not just cache, another difficulty is in OS difference, he needs not just binary translate but have something akin to WINE too while he recompiles code

      • I Cast Fist@programming.dev
        link
        fedilink
        English
        arrow-up
        0
        ·
        7 months ago

        If he’s compiling from windows to windows, target OS shouldn’t be a problem. Also, I just had to go one extra click to read Mr-Wiseguy’s github 😅

        He could also, in theory, use Cosmopolitan to generate an APE (Actually Portable Executable) that will run on linux, bsd, windows and mac. I had to find a video where Justine talks about it to understand how and why it works: it’s basically a trick to rewrite the header of the executable, with the real magic being an “optional shebang” that lets both Windows and *Nix run the first bytes.