diff --git a/libc-top-half/musl/src/internal/pthread_impl.h b/libc-top-half/musl/src/internal/pthread_impl.h index 1e7b9741..0106ac38 100644 --- a/libc-top-half/musl/src/internal/pthread_impl.h +++ b/libc-top-half/musl/src/internal/pthread_impl.h @@ -186,8 +186,10 @@ static inline void __wake(volatile void *addr, int cnt, int priv) __syscall(SYS_futex, addr, FUTEX_WAKE|priv, cnt) != -ENOSYS || __syscall(SYS_futex, addr, FUTEX_WAKE, cnt); #else +#ifdef _REENTRANT __builtin_wasm_memory_atomic_notify((int*)addr, cnt); #endif +#endif } static inline void __futexwait(volatile void *addr, int val, int priv) {