Skip to content

Remove support for PTHREAD_PROCESS_SHARED locks, etc#26743

Merged
sbc100 merged 1 commit intoemscripten-core:mainfrom
sbc100:process_shared
Apr 22, 2026
Merged

Remove support for PTHREAD_PROCESS_SHARED locks, etc#26743
sbc100 merged 1 commit intoemscripten-core:mainfrom
sbc100:process_shared

Conversation

@sbc100
Copy link
Copy Markdown
Collaborator

@sbc100 sbc100 commented Apr 21, 2026

Emscripten does not support these. See #26733 for the start of this project.

@sbc100 sbc100 force-pushed the process_shared branch 2 times, most recently from ca74bc4 to 2e04ac6 Compare April 21, 2026 22:53
((char *)next - sizeof(void *)) = &m->_m_next;
self->robust_list.head = &m->_m_next;
#ifndef __EMSCRIPTEN__ // XXX Emscripten does not support process-shared locks.
self->robust_list.pending = 0;
Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@stephenduong1004 I think this line is where your crash is coming from.

Hopefully this change will fix it.

Comment thread system/lib/libc/musl/src/thread/pthread_mutex_timedlock.c Outdated
Comment thread system/lib/libc/musl/src/thread/pthread_mutex_trylock.c Outdated
Copy link
Copy Markdown
Member

@kripken kripken left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, I don't want to hold this up if it's urgently needed, but I do hope we can find a nicer solution that reduces the diff vs. musl

@sbc100
Copy link
Copy Markdown
Collaborator Author

sbc100 commented Apr 22, 2026

Ok, I don't want to hold this up if it's urgently needed, but I do hope we can find a nicer solution that reduces the diff vs. musl

Maybe I'll split out the wasm worker fix and keep this PR more focused.

Emscripten does not support these. See emscripten-core#26733 for the start of this
project.
@sbc100 sbc100 changed the title Remove support for PTHREAD_PROCESS_SHARED locks Remove support for PTHREAD_PROCESS_SHARED locks, etc Apr 22, 2026
@sbc100 sbc100 requested a review from kripken April 22, 2026 20:15
@sbc100
Copy link
Copy Markdown
Collaborator Author

sbc100 commented Apr 22, 2026

This change is now much more focused.

@sbc100 sbc100 merged commit 69bc70b into emscripten-core:main Apr 22, 2026
29 checks passed
@sbc100 sbc100 deleted the process_shared branch April 22, 2026 22:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants