-
Notifications
You must be signed in to change notification settings - Fork 192
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Issue about errno when using WASI #241
Comments
This is most likely because non of the wasi-sdk core libraries such as libc and libc++ and compiler-rt are compiled with threading support. In order to experiment with threading you would need to rebuild the whole SDK with Also, you don't need |
@sbc100 when i remove |
Ok, so |
I guess this is really a duplicate of WebAssembly/WASI#296 and can probably be closes as such? |
Yes, this is being pursued in https://reviews.llvm.org/D130053 and WebAssembly/wasi-libc#307. |
this still seems to be the case with wasi-sdk-24. if that flag is required for correct behavior when using the new wasi threads target, shouldn't it be implied automatically? |
you don't need to "rebuild the whole SDK" as the recent wasi-sdk ships wasi-threads build of the libraries. |
sorry, meant to emphasize the consistent usage of the flag, not rebuilding the sdk. if you use the threads target but not the pthreads flag, things will link, but you end up with multiple errno storage as described in this report. so if the pthreads flag is required, why isn't it implied when using the threads target? |
I am testing the WASI by thread example, and find an issue about
errno
, my steps are following:The result is
relocation R_WASM_MEMORY_ADDR_TLS_SLEB cannot be used against
errnoin non-TLS section: .bss
.My thread code is following:
The text was updated successfully, but these errors were encountered: