Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

i#6611: Fix pthread lock hang #6626

Merged
merged 5 commits into from
Feb 6, 2024
Merged

i#6611: Fix pthread lock hang #6626

merged 5 commits into from
Feb 6, 2024

Conversation

derekbruening
Copy link
Contributor

@derekbruening derekbruening commented Feb 5, 2024

Fixes a hang on glibc 2.37 by initializing the tid pthread TLS field. Its offset is located by decoding an exported function known to reference it in a new routine privload_set_pthread_tls_fields().

Only x86 is supported with this fix as no aarch64 machine with the required glibc is available for developing and testing the decode fix.

Tested on a glibc 2.37 machine where without this fix the client.drcallstack test hangs in release build.

Also tested on a Dr. Memory 2.6.19737 build pointing at a release build DR with this fix and confirmed it fixes the hang there.

Fixes #6611

Fixes a hang on glibc 2.37 by initializing the tid pthread TLS field.
Its offset is located by decoding an exported function known to
reference it in a new routine privload_set_pthread_tls_fields().

Tested on a glibc 2.37 machine where without this fix the
client.drcallstack test hangs in release build.

Also tested on a Dr. Memory 2.6.19737 build pointing at a release
build DR with this fix and confirmed it fixes the hang there.

Fixes #6611
core/unix/loader_linux.c Show resolved Hide resolved
core/unix/loader_linux.c Outdated Show resolved Hide resolved
core/unix/loader_linux.c Outdated Show resolved Hide resolved
core/unix/loader_linux.c Show resolved Hide resolved
@derekbruening derekbruening merged commit 7e3fb44 into master Feb 6, 2024
15 checks passed
@derekbruening derekbruening deleted the i6611-pthread-tid-hang branch February 6, 2024 17:20
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.

HANG in elfutils libdw in looking up line numbers with drsyms
2 participants