Add exception-handling and shared-memory feature flags#178
Open
jurgelenas wants to merge 1 commit intobytecodealliance:mainfrom
Open
Add exception-handling and shared-memory feature flags#178jurgelenas wants to merge 1 commit intobytecodealliance:mainfrom
jurgelenas wants to merge 1 commit intobytecodealliance:mainfrom
Conversation
b91ba01 to
2d2c631
Compare
Fix a bug in set_wasi_context where Vec<CString> was cast directly to *const c_char. CString is a 24-byte struct, not an 8-byte pointer, so WAMR received garbage pointers for preopened directory paths, causing segfaults in os_realpath during module instantiation. The fix collects CString pointers into a separate Vec<*const c_char> stored on the Module struct, matching how env and args are already handled. New configurable feature flags: - exception-handling: WAMR_BUILD_EXCE_HANDLING - shared-memory: WAMR_BUILD_SHARED_MEMORY + WAMR_BUILD_THREAD_MGR - wasi-threads: WAMR_BUILD_LIB_WASI_THREADS (implies shared-memory) - fast-interp: WAMR_BUILD_FAST_INTERP Also makes wamrc (AOT compiler) build conditional on the llvmjit feature, so users without LLVM can build for interpreter-only use.
171dca2 to
9de5c85
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fix WASI path pointer cast and add new feature flags.
Fix a bug in set_wasi_context where Vec was cast directly to *const c_char. CString is a 24-byte struct, not an 8-byte pointer, so WAMR received garbage pointers for preopened directory paths, causing segfaults in os_realpath during module instantiation.
The fix collects CString pointers into a separate Vec<*const c_char> stored on the Module struct, matching how env and args are already handled.
New configurable feature flags:
Also makes wamrc (AOT compiler) build conditional on the llvmjit feature, so users without LLVM can build for interpreter-only use.