This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
[PATCH v2] Destructor support for C++11 thread_local variables -abilist entries
Hi,
As Roland requested, I have resubmitted a single patch with the abilist
changes included. The patch is simply the earlier two patches combined:
http://sourceware.org/ml/libc-alpha/2012-10/msg00289.html
http://sourceware.org/ml/libc-alpha/2012-10/msg00322.html
Siddhesh
ChangeLog:
* include/stdlib.h (__cxa_thread_atexit_impl): Declare.
(__call_tls_dtors): Likewise.
* sysdeps/unix/sysv/linux/i386/nptl/libc.abilist: Add
__cxa_thread_atexit_impl.
* sysdeps/unix/sysv/linux/powerpc/powerpc32/fpu/nptl/libc.abilist:
Likewise.
* sysdeps/unix/sysv/linux/powerpc/powerpc64/nptl/libc.abilist:
Likewise.
* sysdeps/unix/sysv/linux/s390/s390-32/nptl/libc.abilist:
Likewise.
* sysdeps/unix/sysv/linux/s390/s390-64/nptl/libc.abilist:
Likewise.
* sysdeps/unix/sysv/linux/sh/nptl/libc.abilist: Likewise.
* sysdeps/unix/sysv/linux/sparc/sparc32/nptl/libc.abilist:
Likewise.
* sysdeps/unix/sysv/linux/sparc/sparc64/nptl/libc.abilist:
Likewise.
* sysdeps/unix/sysv/linux/x86_64/64/nptl/libc.abilist: Likewise.
* sysdeps/unix/sysv/linux/x86_64/x32/nptl/libc.abilist:
Likewise.
* stdlib/Makefile (routines): Add __cxa_thread_atexit_impl.
* stdlib/Versions (GLIBC_2.17): Likewise.
(GLIBC_PRIVATE): Add __call_tls_dtors.
* stdlib/cxa_thread_atexit_impl.c: New file with helper function
for libstdc++.
* stdlib/exit.c (__run_exit_handlers): Call __call_tls_dtors.
nptl/ChangeLog:
* pthread_create.c (start_thread): Call __call_tls_dtors.
ChangeLog.alpha:
2012-10-11 Siddhesh Poyarekar <siddhesh@redhat.com>
* sysdeps/unix/sysv/linux/alpha/nptl/libc.abilist: Add
__cxa_thread_atexit_impl.
ChangeLog.arm:
2012-10-11 Siddhesh Poyarekar <siddhesh@redhat.com>
* sysdeps/unix/sysv/linux/arm/nptl/libc.abilist: Add
__cxa_thread_atexit_impl.
ChangeLog.ia64:
2012-10-11 Siddhesh Poyarekar <siddhesh@redhat.com>
* sysdeps/unix/sysv/linux/ia64/nptl/libc.abilist: Add
__cxa_thread_atexit_impl.
ChangeLog.m68k:
2012-10-11 Siddhesh Poyarekar <siddhesh@redhat.com>
* sysdeps/unix/sysv/linux/m68k/coldfire/nptl/libc.abilist: Add
__cxa_thread_atexit_impl.
* sysdeps/unix/sysv/linux/m68k/m680x0/nptl/libc.abilist:
Likewise.
ChangeLog.mips:
2012-10-11 Siddhesh Poyarekar <siddhesh@redhat.com>
* sysdeps/unix/sysv/linux/mips/mips32/nptl/libc.abilist: Add
__cxa_thread_atexit_impl.
* sysdeps/unix/sysv/linux/mips/mips64/n32/nptl/libc.abilist:
Likewise.
* sysdeps/unix/sysv/linux/mips/mips64/n64/nptl/libc.abilist:
Likewise.
ChangeLog.powerpc:
2012-10-11 Siddhesh Poyarekar <siddhesh@redhat.com>
* sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/nptl/libc.abilist:
Add __cxa_thread_atexit_impl.
* sysdeps/unix/sysv/linux/tile/tilegx/tilegx32/nptl/libc.abilist:
Likewise.
ChangeLog.tile:
2012-10-11 Siddhesh Poyarekar <siddhesh@redhat.com>
* sysdeps/unix/sysv/linux/tile/tilegx/tilegx64/nptl/libc.abilist:
Add __cxa_thread_atexit_impl.
* sysdeps/unix/sysv/linux/tile/tilepro/nptl/libc.abilist:
Likewise.
diff --git a/include/stdlib.h b/include/stdlib.h
index d45b2f0..4387394 100644
--- a/include/stdlib.h
+++ b/include/stdlib.h
@@ -99,6 +99,10 @@ extern int __cxa_atexit (void (*func) (void *), void *arg, void *d);
extern int __cxa_atexit_internal (void (*func) (void *), void *arg, void *d)
attribute_hidden;
+extern int __cxa_thread_atexit_impl (void (*func) (void *), void *arg,
+ void *d);
+extern void __call_tls_dtors (void);
+
extern void __cxa_finalize (void *d);
extern int __posix_memalign (void **memptr, size_t alignment, size_t size);
diff --git a/nptl/pthread_create.c b/nptl/pthread_create.c
index 197dfa7..34c0d30 100644
--- a/nptl/pthread_create.c
+++ b/nptl/pthread_create.c
@@ -311,6 +311,9 @@ start_thread (void *arg)
#endif
}
+ /* Call destructors for the thread_local TLS variables. */
+ __call_tls_dtors ();
+
/* Run the destructor for the thread-local data. */
__nptl_deallocate_tsd ();
diff --git a/ports/sysdeps/unix/sysv/linux/alpha/nptl/libc.abilist b/ports/sysdeps/unix/sysv/linux/alpha/nptl/libc.abilist
index f8a3295..a694475 100644
--- a/ports/sysdeps/unix/sysv/linux/alpha/nptl/libc.abilist
+++ b/ports/sysdeps/unix/sysv/linux/alpha/nptl/libc.abilist
@@ -1813,6 +1813,7 @@ GLIBC_2.16
timespec_get F
GLIBC_2.17
GLIBC_2.17 A
+ __cxa_thread_atexit_impl F
secure_getenv F
GLIBC_2.2
GLIBC_2.2 A
diff --git a/ports/sysdeps/unix/sysv/linux/arm/nptl/libc.abilist b/ports/sysdeps/unix/sysv/linux/arm/nptl/libc.abilist
index 5523fdd..7fe5513 100644
--- a/ports/sysdeps/unix/sysv/linux/arm/nptl/libc.abilist
+++ b/ports/sysdeps/unix/sysv/linux/arm/nptl/libc.abilist
@@ -80,6 +80,7 @@ GLIBC_2.16
timespec_get F
GLIBC_2.17
GLIBC_2.17 A
+ __cxa_thread_atexit_impl F
secure_getenv F
GLIBC_2.4
GLIBC_2.4 A
diff --git a/ports/sysdeps/unix/sysv/linux/ia64/nptl/libc.abilist b/ports/sysdeps/unix/sysv/linux/ia64/nptl/libc.abilist
index b73f5ca..0641368 100644
--- a/ports/sysdeps/unix/sysv/linux/ia64/nptl/libc.abilist
+++ b/ports/sysdeps/unix/sysv/linux/ia64/nptl/libc.abilist
@@ -80,6 +80,7 @@ GLIBC_2.16
timespec_get F
GLIBC_2.17
GLIBC_2.17 A
+ __cxa_thread_atexit_impl F
secure_getenv F
GLIBC_2.2
GLIBC_2.2 A
diff --git a/ports/sysdeps/unix/sysv/linux/m68k/coldfire/nptl/libc.abilist b/ports/sysdeps/unix/sysv/linux/m68k/coldfire/nptl/libc.abilist
index 9a92457..d13c993 100644
--- a/ports/sysdeps/unix/sysv/linux/m68k/coldfire/nptl/libc.abilist
+++ b/ports/sysdeps/unix/sysv/linux/m68k/coldfire/nptl/libc.abilist
@@ -81,6 +81,7 @@ GLIBC_2.16
timespec_get F
GLIBC_2.17
GLIBC_2.17 A
+ __cxa_thread_atexit_impl F
secure_getenv F
GLIBC_2.4
GLIBC_2.4 A
diff --git a/ports/sysdeps/unix/sysv/linux/m68k/m680x0/nptl/libc.abilist b/ports/sysdeps/unix/sysv/linux/m68k/m680x0/nptl/libc.abilist
index fbcd208..b49279a 100644
--- a/ports/sysdeps/unix/sysv/linux/m68k/m680x0/nptl/libc.abilist
+++ b/ports/sysdeps/unix/sysv/linux/m68k/m680x0/nptl/libc.abilist
@@ -1769,6 +1769,7 @@ GLIBC_2.16
timespec_get F
GLIBC_2.17
GLIBC_2.17 A
+ __cxa_thread_atexit_impl F
secure_getenv F
GLIBC_2.2
GLIBC_2.2 A
diff --git a/ports/sysdeps/unix/sysv/linux/mips/mips32/nptl/libc.abilist b/ports/sysdeps/unix/sysv/linux/mips/mips32/nptl/libc.abilist
index 54e8d1a..bc30e5a 100644
--- a/ports/sysdeps/unix/sysv/linux/mips/mips32/nptl/libc.abilist
+++ b/ports/sysdeps/unix/sysv/linux/mips/mips32/nptl/libc.abilist
@@ -2244,4 +2244,5 @@ _gp_disp
_gp_disp A
GLIBC_2.17
GLIBC_2.17 A
+ __cxa_thread_atexit_impl F
secure_getenv F
diff --git a/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/nptl/libc.abilist b/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/nptl/libc.abilist
index 2a0e2a2..5cd77ab 100644
--- a/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/nptl/libc.abilist
+++ b/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/nptl/libc.abilist
@@ -1392,6 +1392,7 @@ GLIBC_2.16
timespec_get F
GLIBC_2.17
GLIBC_2.17 A
+ __cxa_thread_atexit_impl F
secure_getenv F
GLIBC_2.2
GLIBC_2.2 A
diff --git a/ports/sysdeps/unix/sysv/linux/mips/mips64/n64/nptl/libc.abilist b/ports/sysdeps/unix/sysv/linux/mips/mips64/n64/nptl/libc.abilist
index 0e21194..2c61be9 100644
--- a/ports/sysdeps/unix/sysv/linux/mips/mips64/n64/nptl/libc.abilist
+++ b/ports/sysdeps/unix/sysv/linux/mips/mips64/n64/nptl/libc.abilist
@@ -1390,6 +1390,7 @@ GLIBC_2.16
timespec_get F
GLIBC_2.17
GLIBC_2.17 A
+ __cxa_thread_atexit_impl F
secure_getenv F
GLIBC_2.2
GLIBC_2.2 A
diff --git a/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/nptl/libc.abilist b/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/nptl/libc.abilist
index 481162e..cfde8d2 100644
--- a/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/nptl/libc.abilist
+++ b/ports/sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/nptl/libc.abilist
@@ -1774,6 +1774,7 @@ GLIBC_2.16
timespec_get F
GLIBC_2.17
GLIBC_2.17 A
+ __cxa_thread_atexit_impl F
secure_getenv F
__ppc_get_timebase_freq F
GLIBC_2.2
diff --git a/ports/sysdeps/unix/sysv/linux/tile/tilegx/tilegx32/nptl/libc.abilist b/ports/sysdeps/unix/sysv/linux/tile/tilegx/tilegx32/nptl/libc.abilist
index 48f0c69..09b3aee 100644
--- a/ports/sysdeps/unix/sysv/linux/tile/tilegx/tilegx32/nptl/libc.abilist
+++ b/ports/sysdeps/unix/sysv/linux/tile/tilegx/tilegx32/nptl/libc.abilist
@@ -2082,4 +2082,5 @@ GLIBC_2.16
timespec_get F
GLIBC_2.17
GLIBC_2.17 A
+ __cxa_thread_atexit_impl F
secure_getenv F
diff --git a/ports/sysdeps/unix/sysv/linux/tile/tilegx/tilegx64/nptl/libc.abilist b/ports/sysdeps/unix/sysv/linux/tile/tilegx/tilegx64/nptl/libc.abilist
index 3aa70a1..f8d2190 100644
--- a/ports/sysdeps/unix/sysv/linux/tile/tilegx/tilegx64/nptl/libc.abilist
+++ b/ports/sysdeps/unix/sysv/linux/tile/tilegx/tilegx64/nptl/libc.abilist
@@ -2082,4 +2082,5 @@ GLIBC_2.16
timespec_get F
GLIBC_2.17
GLIBC_2.17 A
+ __cxa_thread_atexit_impl F
secure_getenv F
diff --git a/ports/sysdeps/unix/sysv/linux/tile/tilepro/nptl/libc.abilist b/ports/sysdeps/unix/sysv/linux/tile/tilepro/nptl/libc.abilist
index 48f0c69..09b3aee 100644
--- a/ports/sysdeps/unix/sysv/linux/tile/tilepro/nptl/libc.abilist
+++ b/ports/sysdeps/unix/sysv/linux/tile/tilepro/nptl/libc.abilist
@@ -2082,4 +2082,5 @@ GLIBC_2.16
timespec_get F
GLIBC_2.17
GLIBC_2.17 A
+ __cxa_thread_atexit_impl F
secure_getenv F
diff --git a/stdlib/Makefile b/stdlib/Makefile
index a5318ee..d514bba 100644
--- a/stdlib/Makefile
+++ b/stdlib/Makefile
@@ -33,7 +33,7 @@ routines := \
bsearch qsort msort \
getenv putenv setenv secure-getenv \
exit on_exit atexit cxa_atexit cxa_finalize old_atexit \
- quick_exit at_quick_exit cxa_at_quick_exit \
+ quick_exit at_quick_exit cxa_at_quick_exit cxa_thread_atexit_impl \
abs labs llabs \
div ldiv lldiv \
mblen mbstowcs mbtowc wcstombs wctomb \
diff --git a/stdlib/Versions b/stdlib/Versions
index 250bd5f..50dec5d 100644
--- a/stdlib/Versions
+++ b/stdlib/Versions
@@ -105,6 +105,7 @@ libc {
}
GLIBC_2.17 {
secure_getenv;
+ __cxa_thread_atexit_impl;
}
GLIBC_PRIVATE {
# functions which have an additional interface since they are
@@ -114,5 +115,6 @@ libc {
__abort_msg;
# Used from other libraries
__libc_secure_getenv;
+ __call_tls_dtors;
}
}
diff --git a/stdlib/cxa_thread_atexit_impl.c b/stdlib/cxa_thread_atexit_impl.c
new file mode 100644
index 0000000..74e068a
--- /dev/null
+++ b/stdlib/cxa_thread_atexit_impl.c
@@ -0,0 +1,94 @@
+/* Register destructors for C++ TLS variables declared with thread_local.
+ Copyright (C) 2012 Free Software Foundation, Inc.
+ This file is part of the GNU C Library.
+
+ The GNU C Library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 of the License, or (at your option) any later version.
+
+ The GNU C Library is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, see
+ <http://www.gnu.org/licenses/>. */
+
+#include <stdlib.h>
+#include <ldsodefs.h>
+
+typedef void (*dtor_func) (void *);
+
+struct dtor_list
+{
+ dtor_func func;
+ void *obj;
+ struct dtor_list *next;
+};
+
+static __thread struct dtor_list *tls_dtor_list;
+
+/* Register a destructor for TLS variables declared with the 'thread_local'
+ keyword. This function is only called from code generated by the C++
+ compiler. */
+int
+__cxa_thread_atexit_impl (dtor_func func, void *obj, void *dso_handle)
+{
+ static void *dso_handle_cache;
+
+ /* Prepend. */
+ struct dtor_list *new = calloc (1, sizeof (struct dtor_list));
+ new->func = func;
+ new->obj = obj;
+ new->next = tls_dtor_list;
+ tls_dtor_list = new;
+
+ if (__builtin_expect (dso_handle_cache != dso_handle, 0))
+ {
+ ElfW(Addr) caller = (ElfW(Addr)) dso_handle;
+
+ __rtld_lock_lock_recursive (GL(dl_load_lock));
+
+ /* If the address is not recognized the call comes from the main
+ program (we hope). */
+ struct link_map *match = GL(dl_ns)[LM_ID_BASE]._ns_loaded;
+
+ /* Find the highest-addressed object that DSO_HANDLE is not below. */
+ for (Lmid_t ns = 0; ns < GL(dl_nns); ++ns)
+ for (struct link_map *l = GL(dl_ns)[ns]._ns_loaded; l != NULL;
+ l = l->l_next)
+ if (caller >= l->l_map_start && caller < l->l_map_end
+ && (l->l_contiguous || _dl_addr_inside_object (l, caller)))
+ {
+ match = l;
+ break;
+ }
+
+ if (match->l_type == lt_loaded)
+ match->l_flags_1 |= DF_1_NODELETE;
+ dso_handle_cache = dso_handle;
+
+ __rtld_lock_unlock_recursive (GL(dl_load_lock));
+ }
+ return 0;
+}
+
+/* Call the destructors. This is called either when a thread returns from the
+ initial function or when the process exits via the exit(3) function. */
+void
+__call_tls_dtors (void)
+{
+ struct dtor_list *l = tls_dtor_list;
+
+ while (l)
+ {
+ struct dtor_list *cur = l;
+
+ l = l->next;
+ cur->func (cur->obj);
+ free (cur);
+ }
+ tls_dtor_list = NULL;
+}
diff --git a/stdlib/exit.c b/stdlib/exit.c
index 1ad548f..78cb9f5 100644
--- a/stdlib/exit.c
+++ b/stdlib/exit.c
@@ -25,7 +25,6 @@
#include "set-hooks.h"
DEFINE_HOOK (__libc_atexit, (void))
-
/* Call all functions registered with `atexit' and `on_exit',
in the reverse of the order in which they were registered
perform stdio cleanup, and terminate program execution with STATUS. */
@@ -34,6 +33,9 @@ attribute_hidden
__run_exit_handlers (int status, struct exit_function_list **listp,
bool run_list_atexit)
{
+ /* First, call the TLS destructors. */
+ __call_tls_dtors ();
+
/* We do it this way to handle recursive calls to exit () made by
the functions registered with `atexit' and `on_exit'. We call
everyone on the list and use the status value in the last
diff --git a/sysdeps/unix/sysv/linux/i386/nptl/libc.abilist b/sysdeps/unix/sysv/linux/i386/nptl/libc.abilist
index 0e8576f..cd0dc52 100644
--- a/sysdeps/unix/sysv/linux/i386/nptl/libc.abilist
+++ b/sysdeps/unix/sysv/linux/i386/nptl/libc.abilist
@@ -1813,6 +1813,7 @@ GLIBC_2.16
timespec_get F
GLIBC_2.17
GLIBC_2.17 A
+ __cxa_thread_atexit_impl F
secure_getenv F
GLIBC_2.2
GLIBC_2.2 A
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/fpu/nptl/libc.abilist b/sysdeps/unix/sysv/linux/powerpc/powerpc32/fpu/nptl/libc.abilist
index ab96361..2a8baff 100644
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc32/fpu/nptl/libc.abilist
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/fpu/nptl/libc.abilist
@@ -1774,6 +1774,7 @@ GLIBC_2.16
timespec_get F
GLIBC_2.17
GLIBC_2.17 A
+ __cxa_thread_atexit_impl F
secure_getenv F
__ppc_get_timebase_freq F
GLIBC_2.2
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc64/nptl/libc.abilist b/sysdeps/unix/sysv/linux/powerpc/powerpc64/nptl/libc.abilist
index a60b72a..c90c884 100644
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc64/nptl/libc.abilist
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc64/nptl/libc.abilist
@@ -80,6 +80,7 @@ GLIBC_2.16
timespec_get F
GLIBC_2.17
GLIBC_2.17 A
+ __cxa_thread_atexit_impl F
secure_getenv F
__ppc_get_timebase_freq F
GLIBC_2.3
diff --git a/sysdeps/unix/sysv/linux/s390/s390-32/nptl/libc.abilist b/sysdeps/unix/sysv/linux/s390/s390-32/nptl/libc.abilist
index ff0b82f..eec5ddc 100644
--- a/sysdeps/unix/sysv/linux/s390/s390-32/nptl/libc.abilist
+++ b/sysdeps/unix/sysv/linux/s390/s390-32/nptl/libc.abilist
@@ -1765,6 +1765,7 @@ GLIBC_2.16
timespec_get F
GLIBC_2.17
GLIBC_2.17 A
+ __cxa_thread_atexit_impl F
secure_getenv F
GLIBC_2.2
GLIBC_2.2 A
diff --git a/sysdeps/unix/sysv/linux/s390/s390-64/nptl/libc.abilist b/sysdeps/unix/sysv/linux/s390/s390-64/nptl/libc.abilist
index 2fb0786..f043a08 100644
--- a/sysdeps/unix/sysv/linux/s390/s390-64/nptl/libc.abilist
+++ b/sysdeps/unix/sysv/linux/s390/s390-64/nptl/libc.abilist
@@ -86,6 +86,7 @@ GLIBC_2.16
timespec_get F
GLIBC_2.17
GLIBC_2.17 A
+ __cxa_thread_atexit_impl F
secure_getenv F
GLIBC_2.2
GLIBC_2.2 A
diff --git a/sysdeps/unix/sysv/linux/sh/nptl/libc.abilist b/sysdeps/unix/sysv/linux/sh/nptl/libc.abilist
index 3fd150e..9e64e10 100644
--- a/sysdeps/unix/sysv/linux/sh/nptl/libc.abilist
+++ b/sysdeps/unix/sysv/linux/sh/nptl/libc.abilist
@@ -86,6 +86,7 @@ GLIBC_2.16
timespec_get F
GLIBC_2.17
GLIBC_2.17 A
+ __cxa_thread_atexit_impl F
secure_getenv F
GLIBC_2.2
GLIBC_2.2 A
diff --git a/sysdeps/unix/sysv/linux/sparc/sparc32/nptl/libc.abilist b/sysdeps/unix/sysv/linux/sparc/sparc32/nptl/libc.abilist
index 7d5a342..11361b2 100644
--- a/sysdeps/unix/sysv/linux/sparc/sparc32/nptl/libc.abilist
+++ b/sysdeps/unix/sysv/linux/sparc/sparc32/nptl/libc.abilist
@@ -1770,6 +1770,7 @@ GLIBC_2.16
timespec_get F
GLIBC_2.17
GLIBC_2.17 A
+ __cxa_thread_atexit_impl F
secure_getenv F
GLIBC_2.2
GLIBC_2.2 A
diff --git a/sysdeps/unix/sysv/linux/sparc/sparc64/nptl/libc.abilist b/sysdeps/unix/sysv/linux/sparc/sparc64/nptl/libc.abilist
index 6d6e57c..4427822 100644
--- a/sysdeps/unix/sysv/linux/sparc/sparc64/nptl/libc.abilist
+++ b/sysdeps/unix/sysv/linux/sparc/sparc64/nptl/libc.abilist
@@ -91,6 +91,7 @@ GLIBC_2.16
timespec_get F
GLIBC_2.17
GLIBC_2.17 A
+ __cxa_thread_atexit_impl F
secure_getenv F
GLIBC_2.2
GLIBC_2.2 A
diff --git a/sysdeps/unix/sysv/linux/x86_64/64/nptl/libc.abilist b/sysdeps/unix/sysv/linux/x86_64/64/nptl/libc.abilist
index d6ab153..becaf18 100644
--- a/sysdeps/unix/sysv/linux/x86_64/64/nptl/libc.abilist
+++ b/sysdeps/unix/sysv/linux/x86_64/64/nptl/libc.abilist
@@ -82,6 +82,7 @@ GLIBC_2.16
timespec_get F
GLIBC_2.17
GLIBC_2.17 A
+ __cxa_thread_atexit_impl F
secure_getenv F
GLIBC_2.2.5
GLIBC_2.2.5 A
diff --git a/sysdeps/unix/sysv/linux/x86_64/x32/nptl/libc.abilist b/sysdeps/unix/sysv/linux/x86_64/x32/nptl/libc.abilist
index 65bcead..8d45fc3 100644
--- a/sysdeps/unix/sysv/linux/x86_64/x32/nptl/libc.abilist
+++ b/sysdeps/unix/sysv/linux/x86_64/x32/nptl/libc.abilist
@@ -2080,4 +2080,5 @@ GLIBC_2.16
xprt_unregister F
GLIBC_2.17
GLIBC_2.17 A
+ __cxa_thread_atexit_impl F
secure_getenv F