Refine AOT/JIT code call wasm-c-api import process (#2982)
Allow to invoke the quick call entry wasm_runtime_quick_invoke_c_api_import to call the wasm-c-api import functions to speedup the calling process, which reduces the data copying. Use `wamrc --invoke-c-api-import` to generate the optimized AOT code, and set `jit_options->quick_invoke_c_api_import` true in wasm_engine_new when LLVM JIT is enabled.
This commit is contained in:
@ -221,8 +221,8 @@ typedef struct CApiFuncImport {
|
||||
|
||||
/* The common part of WASMModuleInstanceExtra and AOTModuleInstanceExtra */
|
||||
typedef struct WASMModuleInstanceExtraCommon {
|
||||
void *contexts[WASM_MAX_INSTANCE_CONTEXTS];
|
||||
CApiFuncImport *c_api_func_imports;
|
||||
void *contexts[WASM_MAX_INSTANCE_CONTEXTS];
|
||||
/* pointer to the exec env currently used */
|
||||
WASMExecEnv *cur_exec_env;
|
||||
#if WASM_CONFIGURABLE_BOUNDS_CHECKS != 0
|
||||
|
||||
Reference in New Issue
Block a user