|
|
00db10 |
#
|
|
|
00db10 |
# This is the original fix for bug 1124987 in Fedora.
|
|
|
00db10 |
# This patch should never go upstream. We are applying it
|
|
|
00db10 |
# in rhel-7.2 as a workaround.
|
|
|
00db10 |
#
|
|
|
00db10 |
# Upstream commit f8aeae347377f3dfa8cbadde057adf1827fb1d44 fixes
|
|
|
00db10 |
# this issue correctly, but reveals other bugs, therefore for now
|
|
|
00db10 |
# this patch is a workaround.
|
|
|
00db10 |
#
|
|
|
00db10 |
diff -urN glibc-2.17-c758a686/sysdeps/generic/ldsodefs.h glibc-2.17-c758a686/sysdeps/generic/ldsodefs.h
|
|
|
00db10 |
--- glibc-2.17-c758a686/sysdeps/generic/ldsodefs.h 2014-08-21 01:00:55.000000000 -0400
|
|
|
00db10 |
+++ glibc-2.17-c758a686/sysdeps/generic/ldsodefs.h 2014-09-04 19:29:42.929692810 -0400
|
|
|
00db10 |
@@ -388,8 +388,18 @@
|
|
|
00db10 |
have to iterate beyond the first element in the slotinfo list. */
|
|
|
00db10 |
#define TLS_SLOTINFO_SURPLUS (62)
|
|
|
00db10 |
|
|
|
00db10 |
-/* Number of additional slots in the dtv allocated. */
|
|
|
00db10 |
-#define DTV_SURPLUS (14)
|
|
|
00db10 |
+/* Number of additional allocated dtv slots. This was initially
|
|
|
00db10 |
+ 14, but problems with python, MESA, and X11's uses of static TLS meant
|
|
|
00db10 |
+ that most distributions were very close to this limit when they loaded
|
|
|
00db10 |
+ dynamically interpreted languages that used graphics. The simplest
|
|
|
00db10 |
+ solution was to roughly double the number of slots. The actual static
|
|
|
00db10 |
+ image space usage was relatively small, for example in MESA you
|
|
|
00db10 |
+ had only two dispatch pointers for a total of 16 bytes. If we hit up
|
|
|
00db10 |
+ against this limit again we should start a campaign with the
|
|
|
00db10 |
+ distributions to coordinate the usage of static TLS. Any user of this
|
|
|
00db10 |
+ resource is effectively coordinating a global resource since this
|
|
|
00db10 |
+ surplus is allocated for each thread at startup. */
|
|
|
00db10 |
+#define DTV_SURPLUS (32)
|
|
|
00db10 |
|
|
|
00db10 |
/* Initial dtv of the main thread, not allocated with normal malloc. */
|
|
|
00db10 |
EXTERN void *_dl_initial_dtv;
|