Add wasm_export.h APIs to expose memory type (#3496)
Support to get `wasm_memory_type_t memory_type` from API `wasm_runtime_get_import_type` and `wasm_runtime_get_export_type`, and then get shared flag, initial page cout, maximum page count from the memory_type: ```C bool wasm_memory_type_get_shared(const wasm_memory_type_t memory_type); uint32_t wasm_memory_type_get_init_page_count(const wasm_memory_type_t memory_type); uint32_t wasm_memory_type_get_max_page_count(const wasm_memory_type_t memory_type); ```
This commit is contained in:
@ -520,8 +520,7 @@ set_local_gc_ref(AOTCompFrame *frame, int n, LLVMValueRef value, uint8 ref_type)
|
||||
} while (0)
|
||||
|
||||
#if WASM_ENABLE_MEMORY64 != 0
|
||||
#define IS_MEMORY64 \
|
||||
(comp_ctx->comp_data->memories[0].memory_flags & MEMORY64_FLAG)
|
||||
#define IS_MEMORY64 (comp_ctx->comp_data->memories[0].flags & MEMORY64_FLAG)
|
||||
#define MEMORY64_COND_VALUE(VAL_IF_ENABLED, VAL_IF_DISABLED) \
|
||||
(IS_MEMORY64 ? VAL_IF_ENABLED : VAL_IF_DISABLED)
|
||||
#else
|
||||
|
||||
Reference in New Issue
Block a user