Skip to content

Commit

Permalink
fix staging error
Browse files Browse the repository at this point in the history
  • Loading branch information
victoryang00 committed Jun 7, 2024
1 parent 8bf791e commit 6525b23
Show file tree
Hide file tree
Showing 29 changed files with 101 additions and 571 deletions.
277 changes: 0 additions & 277 deletions .github/workflows/codeql_buildscript.sh

This file was deleted.

34 changes: 0 additions & 34 deletions .github/workflows/codeql_fail_on_error.py

This file was deleted.

1 change: 0 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@ WebAssembly Micro Runtime (WAMR) is a lightweight standalone WebAssembly (Wasm)
- [Berkeley/Posix Socket support](./doc/socket_api.md), ref to [document](./doc/socket_api.md) and [sample](./samples/socket-api)
- [Multi-tier JIT](./product-mini#linux) and [Running mode control](https://bytecodealliance.github.io/wamr.dev/blog/introduction-to-wamr-running-modes/)
- Language bindings: [Go](./language-bindings/go/README.md), [Python](./language-bindings/python/README.md), [Rust](./language-bindings/rust/README.md)
- Language bindings: [Go](./language-bindings/go/README.md), [Python](./language-bindings/python/README.md), [Rust](./language-bindings/rust/README.md)

### Wasm post-MVP features
- [wasm-c-api](https://github.com/WebAssembly/wasm-c-api), ref to [document](doc/wasm_c_api.md) and [sample](samples/wasm-c-api)
Expand Down
13 changes: 2 additions & 11 deletions core/iwasm/aot/aot_runtime.c
Original file line number Diff line number Diff line change
Expand Up @@ -75,11 +75,6 @@ bh_static_assert(offsetof(AOTFrame, sp) == sizeof(uintptr_t) * 5);
bh_static_assert(offsetof(AOTFrame, frame_ref) == sizeof(uintptr_t) * 6);
bh_static_assert(offsetof(AOTFrame, lp) == sizeof(uintptr_t) * 7);

bh_static_assert(offsetof(AOTFrame, ip_offset) == sizeof(uintptr_t) * 4);
bh_static_assert(offsetof(AOTFrame, sp) == sizeof(uintptr_t) * 5);
bh_static_assert(offsetof(AOTFrame, frame_ref) == sizeof(uintptr_t) * 6);
bh_static_assert(offsetof(AOTFrame, lp) == sizeof(uintptr_t) * 7);

static void
set_error_buf(char *error_buf, uint32 error_buf_size, const char *string)
{
Expand Down Expand Up @@ -1056,7 +1051,7 @@ memories_instantiate(AOTModuleInstance *module_inst, AOTModuleInstance *parent,
#if WASM_ENABLE_SHARED_MEMORY != 0
/* Currently we have only one memory instance */
bool is_shared_memory =
module->memories[0].memory_flags & 0x02 ? true : false;
module->memories[0].memory_flags & SHARED_MEMORY_FLAG ? true : false;
if (is_shared_memory && parent != NULL) {
/* Ignore setting memory init data if the memory has been initialized */
return true;
Expand Down Expand Up @@ -3680,7 +3675,7 @@ aot_alloc_frame(WASMExecEnv *exec_env, uint32 func_index)
exec_env, exec_env->restore_call_chain, exec_env->handle);
if (((AOTFrame *)exec_env->cur_frame)->func_index != func_index) {
LOG_DEBUG("NOT MATCH!!!\n");
exit(1);
bh_assert(((AOTFrame *)exec_env->cur_frame)->func_index == func_index);
}
return true;
}
Expand Down Expand Up @@ -3717,10 +3712,6 @@ aot_alloc_frame(WASMExecEnv *exec_env, uint32 func_index)
frame->func_perf_prof_info = func_perf_prof;
#endif
frame->ip_offset = 0;
frame->sp = frame->lp + max_local_cell_num;
#if WASM_ENABLE_GC != 0
frame->frame_ref = frame->sp + max_stack_cell_num;
#endif

#if WASM_ENABLE_GC != 0
frame->sp = frame->lp + max_local_cell_num;
Expand Down
4 changes: 4 additions & 0 deletions core/iwasm/common/wasm_exec_env.c
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,9 @@ wasm_exec_env_create_internal(struct WASMModuleInstanceCommon *module_inst,
exec_env->wasm_stack.top_boundary =
exec_env->wasm_stack.bottom + stack_size;
exec_env->wasm_stack.top = exec_env->wasm_stack.bottom;
#if WASM_ENABLE_CHECKPOINT_RESTORE != 0
exec_env->is_checkpoint = false;
#endif

#if WASM_ENABLE_AOT != 0
if (module_inst->module_type == Wasm_Module_AoT) {
Expand All @@ -86,10 +88,12 @@ wasm_exec_env_create_internal(struct WASMModuleInstanceCommon *module_inst,
wasm_runtime_dump_exec_env_mem_consumption(exec_env);
#endif

#if WASM_ENABLE_CHECKPOINT_RESTORE != 0
exec_env->is_checkpoint = false;
exec_env->is_restore = false;
exec_env->call_chain_size = 0;
exec_env->restore_call_chain = NULL;
#endif
return exec_env;

#ifdef OS_ENABLE_HW_BOUND_CHECK
Expand Down
Loading

0 comments on commit 6525b23

Please sign in to comment.