wa-lang.org/wazero@v1.0.2/internal/engine/compiler/arch_amd64.s (about)

     1  #include "funcdata.h"
     2  #include "textflag.h"
     3  
     4  // nativecall(codeSegment, ce, moduleInstanceAddress)
     5  TEXT ·nativecall(SB),NOSPLIT|NOFRAME,$0-24
     6          MOVQ ce+8(FP),R13                     // Load the address of *callEngine. into amd64ReservedRegisterForCallEngine.
     7          MOVQ moduleInstanceAddress+16(FP),R12 // Load the address of *wasm.ModuleInstance into amd64CallingConventionModuleInstanceAddressRegister.
     8          MOVQ codeSegment+0(FP),AX             // Load the address of native code.
     9          JMP AX                                // Jump to native code.