|
マクロ定義 |
|
#define | START_LOCALARGS 3 |
| | ローカル引数の開始位置
|
|
#define | BC (vm_env.bc) |
| | バイトコード
|
|
#define | BCLEN (vm_env.bclen) |
| | バイトコード長
|
|
#define | CALLSTACK ((vm_reg_t *)vm_env.callstack.stackp) |
| | 呼出しスタック
|
|
#define | CALLSP (vm_env.callstack.sp) |
| | 呼出しスタックのスタックポインタ
|
|
#define | EXCPSTACK ((vm_excp_t *)vm_env.excpstack.stackp) |
| | 例外スタック
|
|
#define | EXCPSP (vm_env.excpstack.sp) |
| | 例外スタックのスタックポインタ
|
|
#define | CURREXCP (vm_env.currexcp) |
| | 現在の例外
|
|
#define | REG (vm_env.reg) |
| | レジスタ
|
|
#define | STACK ((newtRef *)vm_env.stack.stackp) |
| | スタック
|
|
#define | FUNC ((REG).func) |
| | 実行中の関数
|
|
#define | PC ((REG).pc) |
| | プログラムカウンタ
|
|
#define | SP ((REG).sp) |
| | スタックポインタ
|
|
#define | LOCALS ((REG).locals) |
| | ローカルフレーム
|
|
#define | RCVR ((REG).rcvr) |
| | レシーバ
|
|
#define | IMPL ((REG).impl) |
| | インプリメンタ
|
型定義 |
|
typedef void(*) | instruction_t (int16_t b) |
| | 命令セット
|
|
typedef void(*) | simple_instruction_t (void) |
| | シンプル命令
|
|
typedef newtRef(*) | nvm_func_t () |
| | ネイティブ関数
|
関数 |
| static newtErr | NVMGetExceptionErrCode (newtRefArg r, bool dump) |
| static newtRef | NVMMakeExceptionFrame (newtRefArg name, newtRefArg data) |
| static void | NVMClearCurrException (void) |
| static void | NVMSetFn (newtRefArg fn) |
| static void | NVMNoStackFrameForReturn (void) |
| static void | reg_rewind (int32_t sp) |
| static void | reg_pop (void) |
| static void | reg_push (int32_t sp) |
| static void | reg_save (int32_t sp) |
| static newtRef | stk_pop0 (void) |
| static newtRef | stk_pop (void) |
| static void | stk_pop_n (int32_t n, newtRef a[]) |
| static void | stk_remove (uint16_t n) |
| static newtRef | stk_top (void) |
| static void | stk_push (newtRefArg value) |
| static bool | excp_push (newtRefArg sym, newtRefArg pc) |
| static void | excp_pop (void) |
| static vm_excp_t * | excp_top (void) |
| static void | excp_pop_handlers (void) |
| static newtRef | liter_get (int16_t n) |
| static newtRef | iter_new (newtRefArg r, newtRefArg deeply) |
| static void | iter_next (newtRefArg iter) |
| static bool | iter_done (newtRefArg iter) |
| static newtRef | NVMMakeArgsArray (uint16_t numArgs) |
| static void | NVMBindArgs (uint16_t numArgs) |
| static void | NVMThrowBC (newtErr err, newtRefArg value, int16_t pop, bool push) |
| static newtErr | NVMFuncCheck (newtRefArg fn, int16_t numArgs) |
| static void | NVMCallNativeFn (newtRefArg fn, int16_t numArgs) |
| static void | NVMCallNativeFunc (newtRefArg fn, newtRefArg rcvr, int16_t numArgs) |
| static void | NVMFuncCall (newtRefArg fn, int16_t numArgs) |
| static void | NVMMessageSend (newtRefArg impl, newtRefArg receiver, newtRefArg fn, int16_t numArgs) |
| static newtRef | vm_send (int16_t b, newtErr *errP) |
| static newtRef | vm_resend (int16_t b, newtErr *errP) |
| static void | si_pop (void) |
| static void | si_dup (void) |
| static void | si_return (void) |
| static void | si_pushself (void) |
| static void | si_set_lex_scope (void) |
| static void | si_iternext (void) |
| static void | si_iterdone (void) |
| static void | si_pop_handlers (void) |
| static void | fn_add (void) |
| static void | fn_subtract (void) |
| static void | fn_aref (void) |
| static void | fn_set_aref (void) |
| static void | fn_equals (void) |
| static void | fn_not (void) |
| static void | fn_not_equals (void) |
| static void | fn_multiply (void) |
| static void | fn_divide (void) |
| static void | fn_div (void) |
| static void | fn_less_than (void) |
| static void | fn_greater_than (void) |
| static void | fn_greater_or_equal (void) |
| static void | fn_less_or_equal (void) |
| static void | fn_bit_and (void) |
| static void | fn_bit_or (void) |
| static void | fn_bit_not (void) |
| static void | fn_new_iterator (void) |
| static void | fn_length (void) |
| static void | fn_clone (void) |
| static void | fn_set_class (void) |
| static void | fn_add_array_slot (void) |
| static void | fn_stringer (void) |
| static void | fn_has_path (void) |
| static void | fn_classof (void) |
| static void | is_dummy (int16_t b) |
| static void | is_simple_instructions (int16_t b) |
| static void | is_push (int16_t b) |
| static void | is_push_constant (int16_t b) |
| static void | is_call (int16_t b) |
| static void | is_invoke (int16_t b) |
| static void | is_send (int16_t b) |
| static void | is_send_if_defined (int16_t b) |
| static void | is_resend (int16_t b) |
| static void | is_resend_if_defined (int16_t b) |
| static void | is_branch (int16_t b) |
| static void | is_branch_if_true (int16_t b) |
| static void | is_branch_if_false (int16_t b) |
| static void | is_find_var (int16_t b) |
| static void | is_get_var (int16_t b) |
| static void | is_make_frame (int16_t b) |
| static void | is_make_array (int16_t b) |
| static void | is_get_path (int16_t b) |
| static void | is_set_path (int16_t b) |
| static void | is_set_var (int16_t b) |
| static void | is_find_and_set_var (int16_t b) |
| static void | is_incr_var (int16_t b) |
| static void | is_branch_if_loop_not_done (int16_t b) |
| static void | is_freq_func (int16_t b) |
| static void | is_new_handlers (int16_t b) |
| static void | NVMDumpInstResult (FILE *f) |
| static void | NVMDumpInstCode (FILE *f, uint8_t *bc, uint32_t pc, uint16_t len) |
| static void | NVMInitREG (void) |
| static void | NVMInitSTACK (void) |
| static void | NVMCleanSTACK (void) |
| static void | NVMInitGlobalFns0 (void) |
| static void | NVMInitGlobalFns1 (void) |
| static void | NVMInitExGlobalFns (void) |
| static void | NVMInitDebugGlobalFns (void) |
| static void | NVMInitGlobalFns (void) |
| static void | NVMInitGlobalVars (void) |
| static void | NVMInit (void) |
| static void | NVMClean (void) |
| static void | NVMLoop (uint32_t callsp) |
| static newtRef | NVMInterpret2 (nps_syntax_node_t *stree, uint32_t numStree, newtErr *errP) |
| newtRef | NVMSelf (void) |
| newtRef | NVMCurrentFunction (void) |
| newtRef | NVMCurrentImplementor (void) |
| bool | NVMHasVar (newtRefArg name) |
| void | NVMThrowData (newtRefArg name, newtRefArg data) |
| void | NVMThrow (newtRefArg name, newtRefArg data) |
| void | NVMRethrow (void) |
| newtRef | NVMCurrentException (void) |
| void | NVMClearException (void) |
| bool | NVMFuncCheckNumArgs (newtRefArg fn, int16_t numArgs) |
| void | NVMDumpInstName (FILE *f, uint8_t a, int16_t b) |
| void | NVMDumpStackTop (FILE *f, char *s) |
| void | NVMDumpCode (FILE *f, uint8_t *bc, uint32_t len) |
| void | NVMDumpBC (FILE *f, newtRefArg instructions) |
| void | NVMDumpFn (FILE *f, newtRefArg func) |
| void | NVMDumpStacks (FILE *f) |
| void | NVMFnCall (newtRefArg fn, int16_t numArgs) |
| newtRef | NVMCall (newtRefArg fn, int16_t numArgs, newtErr *errP) |
| newtRef | NVMInterpret (newtRefArg fn, newtErr *errP) |
| newtErr | NVMInfo (const char *name) |
| newtRef | NVMInterpretFile (const char *path, newtErr *errP) |
| newtRef | NVMInterpretStr (const char *s, newtErr *errP) |
| newtRef | NVMMessageSendWithArgArray (newtRefArg inImpl, newtRefArg inRcvr, newtRefArg inFunction, newtRefArg inArgs) |
変数 |
|
vm_env_t | vm_env |
| | VM 実行環境
|
| static simple_instruction_t | simple_instructions [] |
| | シンプル命令テーブル
|
| static simple_instruction_t | fn_instructions [] |
| | 関数命令テーブル
|
| static instruction_t | is_instructions [] |
| | 命令セットテーブル
|
| static char * | simple_instruction_names [] |
| | シンプル命令名テーブル
|
| static char * | fn_instruction_names [] |
| | 関数命令名テーブル
|
| static char * | vm_instruction_names [] |
| | 命令セット名テーブル
|