mirror of
https://git.proxmox.com/git/wasi-libc
synced 2025-08-10 17:16:48 +00:00
wasi_thread_start: add a comment (#371)
This commit is contained in:
parent
b8aa39947d
commit
ebd3240030
@ -277,6 +277,11 @@ static int start_c11(void *p)
|
|||||||
__attribute__((export_name("wasi_thread_start")))
|
__attribute__((export_name("wasi_thread_start")))
|
||||||
void wasi_thread_start(int tid, void *p)
|
void wasi_thread_start(int tid, void *p)
|
||||||
{
|
{
|
||||||
|
/*
|
||||||
|
* Note: it's fragile to implement wasi_thread_start in C.
|
||||||
|
* On entry, we don't even have C stack (__stack_pointer)
|
||||||
|
* set up. Be careful when modifying this function.
|
||||||
|
*/
|
||||||
struct start_args *args = p;
|
struct start_args *args = p;
|
||||||
__asm__(".globaltype __tls_base, i32\n"
|
__asm__(".globaltype __tls_base, i32\n"
|
||||||
"local.get %0\n"
|
"local.get %0\n"
|
||||||
|
Loading…
Reference in New Issue
Block a user