mirror of
https://github.com/bytecodealliance/wasm-micro-runtime.git
synced 2024-11-26 15:32:05 +00:00
Fix issue in multi-thread sample (#1458)
Set `WAMR_BUILD_LIB_PTHREAD_SEMAPHORE` for the sample, and update document.
This commit is contained in:
parent
729c4aeeaa
commit
5722fcc40a
|
@ -59,7 +59,7 @@ bh_list_init(bh_list *list);
|
|||
* <code>BH_LIST_ERROR</code> if input is invalid or no memory
|
||||
* available.
|
||||
*/
|
||||
extern bh_list_status
|
||||
bh_list_status
|
||||
bh_list_insert(bh_list *list, void *elem);
|
||||
|
||||
/**
|
||||
|
|
|
@ -77,6 +77,10 @@ cmake -DWAMR_BUILD_PLATFORM=linux -DWAMR_BUILD_TARGET=ARM
|
|||
- **WAMR_BUILD_LIB_PTHREAD**=1/0, default to disable if not set
|
||||
> Note: The dependent feature of lib pthread such as the `shared memory` and `thread manager` will be enabled automatically.
|
||||
|
||||
#### **Enable lib-pthread-semaphore**
|
||||
- **WAMR_BUILD_LIB_PTHREAD_SEMAPHORE**=1/0, default to disable if not set
|
||||
> Note: This feature depends on `lib-pthread`, it will be enabled automatically if this feature is enabled.
|
||||
|
||||
#### **Disable boundary check with hardware trap in AOT or JIT mode**
|
||||
- **WAMR_DISABLE_HW_BOUND_CHECK**=1/0, default to enable if not set and supported by platform
|
||||
> Note: by default only platform linux/darwin/android/vxworks 64-bit will enable boundary check with hardware trap in AOT or JIT mode, and the wamrc tool will generate AOT code without boundary check instructions in all 64-bit targets except SGX to improve performance.
|
||||
|
|
|
@ -45,6 +45,7 @@ set(WAMR_BUILD_JIT 0)
|
|||
set(WAMR_BUILD_LIBC_BUILTIN 1)
|
||||
set(WAMR_BUILD_FAST_INTERP 1)
|
||||
set(WAMR_BUILD_LIB_PTHREAD 1)
|
||||
set(WAMR_BUILD_LIB_PTHREAD_SEMAPHORE 1)
|
||||
|
||||
# compiling and linking flags
|
||||
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -pie -fPIE")
|
||||
|
|
Loading…
Reference in New Issue
Block a user