glibc/sysdeps/nptl
Florian Weimer 508ee037a3 nptl: Use out-of-line wake function in __libc_lock_unlock slow path
This slightly reduces code size, as can be seen below.
__libc_lock_unlock is usually used along with __libc_lock_lock in
the same function.  __libc_lock_lock already has an out-of-line
slow path, so this change should not introduce many additional
non-leaf functions.

This change also fixes a link failure in 32-bit Arm thumb mode
because commit 1f9c804fbd
("nptl: Use internal low-level lock type for !IS_IN (libc)")
introduced __libc_do_syscall calls outside of libc.

Before x86-64:

   text	   data	    bss	    dec	    hex	filename
1937748	  20456	  54896	2013100	 1eb7ac	libc.so.6
  25601	    856	  12768	  39225	   9939	nss/libnss_db.so.2
  40310	    952	  25144	  66406	  10366	nss/libnss_files.so.2

After x86-64:
   text	   data	    bss	    dec	    hex	filename
1935312	  20456	  54896	2010664	 1eae28	libc.so.6
  25559	    864	  12768	  39191	   9917	nss/libnss_db.so.2
  39764	    960	  25144	  65868	  1014c	nss/libnss_files.so.2

Before i686:

2110961	  11272	  39144	2161377	 20fae1	libc.so.6
  27243	    428	  12652	  40323	   9d83	nss/libnss_db.so.2
  43062	    476	  25028	  68566	  10bd6	nss/libnss_files.so.2

After i686:

2107347	  11272	  39144	2157763	 20ecc3	libc.so.6
  26929	    432	  12652	  40013	   9c4d	nss/libnss_db.so.2
  43132	    480	  25028	  68640	  10c20	nss/libnss_files.so.2

Reviewed-by: Adhemerval Zanella  <adhemerval.zanella@linaro.org>
2021-07-09 10:59:22 +02:00
..
bits Update copyright dates with scripts/update-copyrights 2021-01-02 12:17:34 -08:00
sys Update copyright dates with scripts/update-copyrights 2021-01-02 12:17:34 -08:00
_Fork.c posix: Consolidate fork implementation 2021-06-24 10:02:06 -03:00
aio_misc.h Linux: Move aio_init from librt into libc 2021-06-25 11:48:25 +02:00
dl-mutex.c elf, nptl: Resolve recursive lock implementation early 2021-05-10 10:31:41 +02:00
dl-thread_gscope_wait.c Update copyright dates with scripts/update-copyrights 2021-01-02 12:17:34 -08:00
dl-tls_init_tp.c nptl: Move pthreadP.h into sysdeps directory 2021-06-22 09:51:10 +02:00
dl-tunables.list nptl: Add glibc.pthread.stack_cache_size tunable 2021-06-28 16:41:58 +02:00
fork.h Linux: Move timer helper routines from librt to libc 2021-06-25 12:21:12 +02:00
futex-internal.h linux: Only use 64-bit syscall if required for internal futex 2021-06-22 12:09:52 -03:00
gai_misc.h resolv: Move libanl into libc (if libpthread is in libc) 2021-07-02 11:45:00 +02:00
Implies
internaltypes.h Update copyright dates with scripts/update-copyrights 2021-01-02 12:17:34 -08:00
jmp-unwind.c nptl: Move pthreadP.h into sysdeps directory 2021-06-22 09:51:10 +02:00
libc_start_call_main.h nptl: Move pthreadP.h into sysdeps directory 2021-06-22 09:51:10 +02:00
libc-lock.h nptl: Move legacy unwinding implementation into libc 2021-04-21 19:49:50 +02:00
libc-lockP.h nptl: Use internal low-level lock type for !IS_IN (libc) 2021-07-07 08:41:14 +02:00
lowlevellock-futex.h nptl: Consolidate async cancel enable/disable implementation in libc 2021-05-05 17:19:32 +02:00
lowlevellock.h nptl: Use out-of-line wake function in __libc_lock_unlock slow path 2021-07-09 10:59:22 +02:00
Makeconfig Linux: Cleanups after librt move 2021-06-28 09:51:01 +02:00
Makefile Linux: Move timer helper routines from librt to libc 2021-06-25 12:21:12 +02:00
malloc-machine.h Update copyright dates with scripts/update-copyrights 2021-01-02 12:17:34 -08:00
proc_service.h Update copyright dates with scripts/update-copyrights 2021-01-02 12:17:34 -08:00
pthread_atfork_compat.h Consolidate pthread_atfork 2021-06-24 10:04:41 -03:00
pthread_early_init.h nptl: Move pthreadP.h into sysdeps directory 2021-06-22 09:51:10 +02:00
pthread_mutex_conf.h nptl: Move internal symbol __mutex_aconf into libc 2021-04-21 19:49:51 +02:00
pthread-offsets.h nptl: update default pthread-offsets.h 2020-02-10 17:01:21 +01:00
pthread.h y2038: Add support for 64-bit time on legacy ABIs 2021-06-15 10:42:11 -03:00
pthreadP.h Linux: Move aio_init from librt into libc 2021-06-25 11:48:25 +02:00
setxid.h nptl: Move pthreadP.h into sysdeps directory 2021-06-22 09:51:10 +02:00
stdio-lock.h libio: Assume _IO_lock_inexpensive 2021-06-04 09:54:52 -03:00
Subdirs
tcb-offsets.h
thread_db.h Update copyright dates with scripts/update-copyrights 2021-01-02 12:17:34 -08:00
timer_routines.h Update copyright dates with scripts/update-copyrights 2021-01-02 12:17:34 -08:00
tst-mqueue8x.c