aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorH.J. Lu <hjl.tools@gmail.com>2016-05-18 13:41:43 -0700
committerH.J. Lu <hjl.tools@gmail.com>2016-05-18 13:41:55 -0700
commitd29261db22b797e1670730f819f9296251dd42ea (patch)
treecb38ec68ab8e22fb03aa7d5c6f6779e6fa275419
parent48526672b61d8cf65ac7aba40053a81498183104 (diff)
downloadglibc-d29261db22b797e1670730f819f9296251dd42ea.tar
glibc-d29261db22b797e1670730f819f9296251dd42ea.tar.gz
glibc-d29261db22b797e1670730f819f9296251dd42ea.tar.bz2
glibc-d29261db22b797e1670730f819f9296251dd42ea.zip
Don't call internal __pthread_unwind via PLT
Add PTHREAD_UNWIND to replace JUMPTARGET(__pthread_unwind) and define it to __GI___pthread_unwind within libpthread. * sysdeps/unix/sysv/linux/x86_64/cancellation.S (PTHREAD_UNWIND): New (__pthread_unwind): Renamed to ... (PTHREAD_UNWIND): This. (__pthread_enable_asynccancel): Replace JUMPTARGET(__pthread_unwind) with PTHREAD_UNWIND.
-rw-r--r--ChangeLog9
-rw-r--r--sysdeps/unix/sysv/linux/x86_64/cancellation.S6
2 files changed, 13 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index ee3cb0e1b3..02db57a5ee 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2016-05-18 H.J. Lu <hongjiu.lu@intel.com>
+
+ * sysdeps/unix/sysv/linux/x86_64/cancellation.S (PTHREAD_UNWIND):
+ New
+ (__pthread_unwind): Renamed to ...
+ (PTHREAD_UNWIND): This.
+ (__pthread_enable_asynccancel): Replace
+ JUMPTARGET(__pthread_unwind) with PTHREAD_UNWIND.
+
2016-05-18 Joseph Myers <joseph@codesourcery.com>
* sysdeps/unix/sysv/linux/bits/sched.h [__USE_GNU]
diff --git a/sysdeps/unix/sysv/linux/x86_64/cancellation.S b/sysdeps/unix/sysv/linux/x86_64/cancellation.S
index 04a0e59ea8..bd22aa0752 100644
--- a/sysdeps/unix/sysv/linux/x86_64/cancellation.S
+++ b/sysdeps/unix/sysv/linux/x86_64/cancellation.S
@@ -21,9 +21,11 @@
#include <kernel-features.h>
#include "lowlevellock.h"
+#define PTHREAD_UNWIND JUMPTARGET(__pthread_unwind)
#if IS_IN (libpthread)
# if defined SHARED && !defined NO_HIDDEN
-# define __pthread_unwind __GI___pthread_unwind
+# undef PTHREAD_UNWIND
+# define PTHREAD_UNWIND __GI___pthread_unwind
# endif
#else
# ifndef SHARED
@@ -76,7 +78,7 @@ ENTRY(__pthread_enable_asynccancel)
lock
orl $TCB_EXITING_BITMASK, %fs:CANCELHANDLING
mov %fs:CLEANUP_JMP_BUF, %RDI_LP
- call JUMPTARGET(__pthread_unwind)
+ call PTHREAD_UNWIND
hlt
END(__pthread_enable_asynccancel)