@@ -1034,43 +1034,6 @@ do_branch(struct exec_context *ctx, uint32_t labelidx, bool goto_else)
10341034 rewind_stack (ctx , height , arity );
10351035}
10361036
1037- int
1038- fetch_exec_next_insn (const uint8_t * p , struct cell * stack ,
1039- struct exec_context * ctx )
1040- {
1041- #if !(defined(TOYWASM_USE_SEPARATE_EXECUTE ) && defined(TOYWASM_USE_TAILCALL ))
1042- assert (ctx -> p == p );
1043- #endif
1044- assert (ctx -> event == EXEC_EVENT_NONE );
1045- assert (ctx -> frames .lsize > 0 );
1046- #if defined(TOYWASM_ENABLE_TRACING_INSN )
1047- uint32_t pc = ptr2pc (ctx -> instance -> module , p );
1048- #endif
1049- uint32_t op = * p ++ ;
1050- #if defined(TOYWASM_USE_SEPARATE_EXECUTE )
1051- xlog_trace_insn ("exec %06" PRIx32 ": %s (%02" PRIx32 ")" , pc ,
1052- instructions [op ].name , op );
1053- const struct exec_instruction_desc * desc = & exec_instructions [op ];
1054- #if defined(TOYWASM_USE_TAILCALL )
1055- __musttail
1056- #endif
1057- return desc -> fetch_exec (p , stack , ctx );
1058- #else
1059- const struct instruction_desc * desc = & instructions [op ];
1060- if (__predict_false (desc -> next_table != NULL )) {
1061- op = read_leb_u32_nocheck (& p );
1062- desc = & desc -> next_table [op ];
1063- }
1064- xlog_trace_insn ("exec %06" PRIx32 ": %s" , pc , desc -> name );
1065- assert (desc -> process != NULL );
1066- struct context common_ctx ;
1067- memset (& common_ctx , 0 , sizeof (common_ctx ));
1068- common_ctx .exec = ctx ;
1069- ctx -> p = p ;
1070- return desc -> process (& ctx -> p , NULL , & common_ctx );
1071- #endif
1072- }
1073-
10741037static int
10751038restart_insn (struct exec_context * ctx )
10761039{
0 commit comments