mirror of
https://sourceware.org/git/glibc.git
synced 2025-07-28 00:21:52 +03:00
Avoid PLT when calling __sched_getaffinity_new
This patch adds an internal entry for __sched_getaffinity_new so that __sched_getaffinity_old calls __sched_getaffinity_new without going through PLT. [BZ #18822] * sysdeps/unix/sysv/linux/sched_getaffinity.c (__sched_getaffinity_new): Add libc_hidden_proto and libc_hidden_def.
This commit is contained in:
@ -1,3 +1,10 @@
|
|||||||
|
2015-10-14 H.J. Lu <hongjiu.lu@intel.com>
|
||||||
|
|
||||||
|
[BZ #18822]
|
||||||
|
* sysdeps/unix/sysv/linux/sched_getaffinity.c
|
||||||
|
(__sched_getaffinity_new): Add libc_hidden_proto and
|
||||||
|
libc_hidden_def.
|
||||||
|
|
||||||
2015-10-14 H.J. Lu <hongjiu.lu@intel.com>
|
2015-10-14 H.J. Lu <hongjiu.lu@intel.com>
|
||||||
|
|
||||||
[BZ #19007]
|
[BZ #19007]
|
||||||
|
@ -25,6 +25,11 @@
|
|||||||
|
|
||||||
|
|
||||||
#ifdef __NR_sched_getaffinity
|
#ifdef __NR_sched_getaffinity
|
||||||
|
# if SHLIB_COMPAT (libc, GLIBC_2_3_3, GLIBC_2_3_4)
|
||||||
|
extern int __sched_getaffinity_new (pid_t, size_t, cpu_set_t *);
|
||||||
|
libc_hidden_proto (__sched_getaffinity_new)
|
||||||
|
# endif
|
||||||
|
|
||||||
int
|
int
|
||||||
__sched_getaffinity_new (pid_t pid, size_t cpusetsize, cpu_set_t *cpuset)
|
__sched_getaffinity_new (pid_t pid, size_t cpusetsize, cpu_set_t *cpuset)
|
||||||
{
|
{
|
||||||
@ -44,6 +49,8 @@ versioned_symbol (libc, __sched_getaffinity_new, sched_getaffinity,
|
|||||||
|
|
||||||
|
|
||||||
# if SHLIB_COMPAT (libc, GLIBC_2_3_3, GLIBC_2_3_4)
|
# if SHLIB_COMPAT (libc, GLIBC_2_3_3, GLIBC_2_3_4)
|
||||||
|
libc_hidden_def (__sched_getaffinity_new)
|
||||||
|
|
||||||
int
|
int
|
||||||
attribute_compat_text_section
|
attribute_compat_text_section
|
||||||
__sched_getaffinity_old (pid_t pid, cpu_set_t *cpuset)
|
__sched_getaffinity_old (pid_t pid, cpu_set_t *cpuset)
|
||||||
|
Reference in New Issue
Block a user