bml_vm.c File Reference

#include "vm.h"
#include "_impl.h"
#include <stdio.h>
#include <string.h>
#include <math.h>
#include "fastmath.h"
#include "opcode_chain.h"
#include "object.h"

Defines

#define join_lock_to_thread(_t, _m)   ((thread_t) (((char*)(_m)) - ( ((char*)&(_t)->join_mutex) - ((char*)(_t)) ) ))
 dirty hack : compute thread_t address from thread->join_mutex address. requires a local thread_t variable.

Functions

void _VM_CALL vm_op_clone (vm_t vm, word_t unused)
void _VM_CALL vm_op_push_Int (vm_t vm, word_t data)
void _VM_CALL vm_op_push_Float (vm_t vm, word_t data)
void _VM_CALL vm_op_push_String (vm_t vm, word_t data)
void _VM_CALL vm_op_push_Opcode (vm_t vm, word_t data)
void _VM_CALL vm_op_pop (vm_t vm, word_t unused)
void _VM_CALL vm_op_pop_Int (vm_t vm, word_t data)
void _VM_CALL vm_op_dup_Int (vm_t vm, int data)
void _VM_CALL vm_op_enter_Int (vm_t vm, word_t size)
void _VM_CALL vm_op_leave_Int (vm_t vm, word_t size)
void _VM_CALL vm_op_nop (vm_t vm, word_t data)
 do NOTHING.
void _VM_CALL vm_op_print_Int (vm_t vm, int n)
void _VM_CALL vm_op_SNZ (vm_t vm, int data)
void _VM_CALL vm_op_SZ (vm_t vm, int data)
void _VM_CALL vm_op_jmp_Label (vm_t vm, word_t data)
void _VM_CALL vm_op_call (vm_t vm, word_t unused)
 call Call a function object.
void _VM_CALL vm_op_call_vc (vm_t vm, word_t unused)
 call_vc Call a function object with a virtual closure.
void _VM_CALL vm_op_call_Label (vm_t vm, word_t data)
 call Label : perform intra-segment call.
void _VM_CALL vm_op_retval_Int (vm_t vm, word_t n)
 retval Int : clean the data stack and return one value
void _VM_CALL vm_op_ret_Int (vm_t vm, word_t n)
 ret Int : clean the data stack and return
void _VM_CALL vm_op_instCatcher_Label (vm_t vm, long rel_ofs)
 instCatcher Label : install a catch vector
void _VM_CALL vm_op_uninstCatcher_Label (vm_t vm, long rel_ofs)
 uninstCatcher Label : uninstall a catch vector and jump to offset
void _VM_CALL vm_op_throw (vm_t vm, word_t unused)
 throw pop a piece of data if it is available and use it as an exception.
void _VM_CALL vm_op_getException (vm_t vm, word_t unused)
void _VM_CALL vm_op_getmem_Int (vm_t vm, int n)
void _VM_CALL vm_op_newThread_Label (vm_t vm, word_t rel_ofs)
void _VM_CALL vm_op_getPid (vm_t vm, word_t unused)
void _VM_CALL vm_op_newMtx (vm_t vm, word_t unused)
void _VM_CALL vm_op_lockMtx_Int (vm_t vm, long memcell)
void _VM_CALL vm_op_unlockMtx_Int (vm_t vm, long memcell)
void _VM_CALL vm_op_lockMtx (vm_t vm, word_t unused)
void _VM_CALL vm_op_unlockMtx (vm_t vm, word_t unused)
void _VM_CALL vm_op_joinThread (vm_t vm, word_t unused)
void _VM_CALL vm_op_killThread (vm_t vm, word_t unused)
void _VM_CALL vm_op_yield (vm_t vm, word_t unused)
void _VM_CALL vm_op_dynFunNew_Label (vm_t vm, word_t rel_ofs)
void _VM_CALL vm_op_dynFunAddClosure (vm_t vm, word_t unused)


Generated on Wed Feb 6 14:46:05 2008 for TinyaML by  doxygen 1.5.3