mirror of
https://github.com/bytecodealliance/wasm-micro-runtime.git
synced 2025-05-09 13:16:26 +00:00
samples/spawn-thread: Tweak to expose a bug (#2888)
this would expose the deadlock bug, which has been fixed by https://github.com/bytecodealliance/wasm-micro-runtime/pull/2882
This commit is contained in:
parent
2fb3dc3ec0
commit
1dbae404b4
|
@ -29,6 +29,7 @@ set (DEFINED_SYMBOLS
|
||||||
set (CMAKE_EXE_LINKER_FLAGS
|
set (CMAKE_EXE_LINKER_FLAGS
|
||||||
"-Wl,--shared-memory,--max-memory=131072, \
|
"-Wl,--shared-memory,--max-memory=131072, \
|
||||||
-Wl,--no-entry,--strip-all,--export=sum, \
|
-Wl,--no-entry,--strip-all,--export=sum, \
|
||||||
|
-Wl,--export=return_bss, \
|
||||||
-Wl,--export=__heap_base,--export=__data_end \
|
-Wl,--export=__heap_base,--export=__data_end \
|
||||||
-Wl,--export=__wasm_call_ctors \
|
-Wl,--export=__wasm_call_ctors \
|
||||||
-Wl,--allow-undefined-file=${DEFINED_SYMBOLS}"
|
-Wl,--allow-undefined-file=${DEFINED_SYMBOLS}"
|
||||||
|
|
|
@ -3,6 +3,17 @@
|
||||||
* SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
|
* SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
/*
|
||||||
|
* have something in bss so that llvm synthesizes
|
||||||
|
* wasm start function for this module.
|
||||||
|
*/
|
||||||
|
char *
|
||||||
|
return_bss()
|
||||||
|
{
|
||||||
|
static char bss[4096];
|
||||||
|
return bss;
|
||||||
|
}
|
||||||
|
|
||||||
int
|
int
|
||||||
sum(int start, int length)
|
sum(int start, int length)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue
Block a user