From 5a664d7ae8e42d641a7b4b436987ff67ab483b08 Mon Sep 17 00:00:00 2001 From: Florian Weimer Date: Tue, 23 Feb 2021 14:59:34 +0100 Subject: nptl: Move elision implementations into libc The elision interfaces are closely aligned between the targets that implement them, so declare them in the generic file. Empty .c stubs are provided, so that fewer makefile updates under sysdeps are needed. Also simplify initialization via __libc_early_init. The symbols __lll_clocklock_elision, __lll_lock_elision, __lll_trylock_elision, __lll_unlock_elision, __pthread_force_elision move into libc. For the time being, non-hidden references are used from libpthread to access them, but once that part of libpthread is moved into libc, hidden symbols will be used again. (Hidden references seem desirable to reduce the likelihood of transactions aborts.) --- sysdeps/unix/sysv/linux/powerpc/elision-conf.h | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'sysdeps/unix/sysv/linux/powerpc/elision-conf.h') diff --git a/sysdeps/unix/sysv/linux/powerpc/elision-conf.h b/sysdeps/unix/sysv/linux/powerpc/elision-conf.h index 8c444d8695..86c677fb7a 100644 --- a/sysdeps/unix/sysv/linux/powerpc/elision-conf.h +++ b/sysdeps/unix/sysv/linux/powerpc/elision-conf.h @@ -22,6 +22,9 @@ #include #include +#define ENABLE_ELISION_SUPPORT 1 +#define ELISION_UNLOCK_NEEDS_ADAPT_COUNT 1 + /* Should make sure there is no false sharing on this. */ struct elision_config { @@ -34,9 +37,4 @@ struct elision_config extern struct elision_config __elision_aconf attribute_hidden; -extern int __pthread_force_elision attribute_hidden; - -/* Tell the test suite to test elision for this architecture. */ -#define HAVE_ELISION 1 - #endif -- cgit 1.4.1