call

Definition: call(atom a)
Description: Call a machine language routine that starts at address a. This routine must execute a RET instruction #C3 to return control to phix. The routine should save and restore any registers that it uses.
Comments: You can allocate() a block of memory for the routine and then poke() in the bytes of machine code. You might allocate other blocks of memory for data and parameters that the machine code can operate on. The addresses of these blocks could be poked into the machine code.
Example Program: demo\dos32\callmach.ex
See Also: allocate, free, peek, poke