Skip to content

Commit d02cec6

Browse files
authored
threads: Enable __lock file for posix thread model (#337)
1 parent 1710f3c commit d02cec6

3 files changed

Lines changed: 3 additions & 2 deletions

File tree

Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -190,6 +190,7 @@ LIBC_TOP_HALF_MUSL_SOURCES = \
190190
ifeq ($(THREAD_MODEL), posix)
191191
LIBC_TOP_HALF_MUSL_SOURCES += \
192192
$(addprefix $(LIBC_TOP_HALF_MUSL_SRC_DIR)/, \
193+
thread/__lock.c \
193194
thread/__wait.c \
194195
thread/__timedwait.c \
195196
thread/pthread_cleanup_push.c \

expected/wasm32-wasi/posix/defined-symbols.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -143,6 +143,7 @@ __loc_is_allocated
143143
__locale_lock
144144
__locale_lockptr
145145
__localtime_r
146+
__lock
146147
__log2_data
147148
__log2f_data
148149
__log_data
@@ -285,6 +286,7 @@ __tre_mem_new_impl
285286
__tsearch_balance
286287
__uflow
287288
__unlist_locked_file
289+
__unlock
288290
__uselocale
289291
__utc
290292
__wait

expected/wasm32-wasi/posix/undefined-symbols.txt

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,6 @@ __imported_wasi_snapshot_preview1_sock_send
6161
__imported_wasi_snapshot_preview1_sock_shutdown
6262
__imported_wasi_snapshot_preview2_thread_spawn
6363
__letf2
64-
__lock
6564
__lockfile
6665
__lttf2
6766
__main_argc_argv
@@ -72,7 +71,6 @@ __thread_list_lock
7271
__tls_base
7372
__trunctfdf2
7473
__trunctfsf2
75-
__unlock
7674
__unlockfile
7775
__unordtf2
7876
__wasilibc_pthread_self

0 commit comments

Comments
 (0)