Skip to content

Prefer to check against thread ID for musl's rwlock. NFC.#15606

Merged
sbc100 merged 1 commit into
emscripten-core:mainfrom
kleisauke:prefer-tid
Nov 23, 2021
Merged

Prefer to check against thread ID for musl's rwlock. NFC.#15606
sbc100 merged 1 commit into
emscripten-core:mainfrom
kleisauke:prefer-tid

Conversation

@kleisauke
Copy link
Copy Markdown
Collaborator

@kleisauke kleisauke commented Nov 23, 2021

Checking against thread IDs should be preferred instead of casting
pthread_self to a pointer. This should be safe to do after commit
b2cfa35.

Split from PR #13007.

Copy link
Copy Markdown
Collaborator

@sbc100 sbc100 left a comment

Choose a reason for hiding this comment

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

lgtm!

Maybe you could add some more detail to the PR description on title?

@kleisauke kleisauke changed the title Check against thread id instead. NFC. Prefer to check against thread ID for musl's rwlock. NFC. Nov 23, 2021
@kleisauke
Copy link
Copy Markdown
Collaborator Author

OK, I changed the PR description and title to be more descriptive. Let me know if you want the commit message changed as well.

(this change was split from commit 4afba04, which uses thread IDs in a couple more places)

@sbc100 sbc100 merged commit d9a4cf9 into emscripten-core:main Nov 23, 2021
@kleisauke kleisauke deleted the prefer-tid branch November 23, 2021 19:28
mmarczell-graphisoft pushed a commit to GRAPHISOFT/emscripten that referenced this pull request Jan 5, 2022
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