RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1764214 - glibc: Fix alignment of TLS variables for tls variant TLS_TCB_AT_TP
Summary: glibc: Fix alignment of TLS variables for tls variant TLS_TCB_AT_TP
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: glibc
Version: 8.2
Hardware: Unspecified
OS: Unspecified
Target Milestone: rc
: 8.0
Assignee: DJ Delorie
QA Contact: qe-baseos-tools-bugs
Oss Tikhomirova
Depends On:
Blocks: 1746918
TreeView+ depends on / blocked
Reported: 2019-10-22 13:31 UTC by Carlos O'Donell
Modified: 2023-07-18 14:30 UTC (History)
8 users (show)

Fixed In Version: glibc-2.28-95
Doc Type: Bug Fix
Doc Text:
.Alignment of TLS variables in `glibc` has been fixed Previously, aligned thread-local storage (TLS) data could, under certain conditions, become instantiated without the expected alignment. With this update, the POSIX Thread Library `libpthread` has been enhanced to ensure correct alignment under any conditions. As a result, aligned TLS data is now correctly instantiated for all threads with the correct alignment.
Clone Of:
Last Closed: 2020-04-28 16:50:19 UTC
Type: Bug
Target Upstream Version:

Attachments (Terms of Use)

System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2020:1828 0 None None None 2020-04-28 16:50:46 UTC
Sourceware 23403 0 P2 RESOLVED Wrong alignment of TLS variables 2021-01-18 00:09:20 UTC

Description Carlos O'Donell 2019-10-22 13:31:25 UTC
We need to backport the following to correct alignment of TLS variables.

commit bc79db3fd487daea36e7c130f943cfb9826a41b4
Author: Stefan Liebler <stli.com>
Date:   Wed Feb 6 09:06:34 2019 +0100

    Fix alignment of TLS variables for tls variant TLS_TCB_AT_TP [BZ #23403]
    The alignment of TLS variables is wrong if accessed from within a thread
    for architectures with tls variant TLS_TCB_AT_TP.
    For the main thread the static tls data is properly aligned.
    For other threads the alignment depends on the alignment of the thread
    pointer as the static tls data is located relative to this pointer.
    This patch adds this alignment for TLS_TCB_AT_TP variants in the same way
    as it is already done for TLS_DTV_AT_TP. The thread pointer is also already
    properly aligned if the user provides its own stack for the new thread.
    This patch extends the testcase nptl/tst-tls1.c in order to check the
    alignment of the tls variables and it adds a pthread_create invocation
    with a user provided stack.
    The test itself is migrated from test-skeleton.c to test-driver.c
    and the missing support functions xpthread_attr_setstack and xposix_memalign
    are added.

Please also verify upstream branch backports:

release/2.30/master - May be required. Please check.
release/2.29/master - May be required. Please check.
release/2.28/master - May be required. Please check.

Comment 2 Sergey Kolosov 2020-02-16 17:09:49 UTC
Verified with the reproducer https://sourceware.org/bugzilla/attachment.cgi?id=11121, the bug is reproduced on s390x and x86_64.

Comment 9 errata-xmlrpc 2020-04-28 16:50:19 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.


Note You need to log in before you can comment on or make changes to this bug.