[v3,4/4] Remove single-thread.h
Checks
Context |
Check |
Description |
dj/TryBot-apply_patch |
success
|
Patch applied to master at the time it was sent
|
dj/TryBot-32bit |
success
|
Build for i686
|
Commit Message
And move SINGLE_THREAD_P macro to sys/single_threaded.h.
---
include/sys/single_threaded.h | 13 ++++++--
sysdeps/generic/single-thread.h | 25 ----------------
sysdeps/mach/hurd/sysdep-cancel.h | 5 ----
sysdeps/unix/sysdep.h | 2 +-
.../unix/sysv/linux/aarch64/single-thread.h | 2 --
sysdeps/unix/sysv/linux/arc/single-thread.h | 2 --
sysdeps/unix/sysv/linux/arm/single-thread.h | 2 --
sysdeps/unix/sysv/linux/hppa/single-thread.h | 2 --
.../sysv/linux/microblaze/single-thread.h | 2 --
sysdeps/unix/sysv/linux/s390/single-thread.h | 2 --
sysdeps/unix/sysv/linux/single-thread.h | 30 -------------------
.../unix/sysv/linux/x86_64/single-thread.h | 2 --
12 files changed, 11 insertions(+), 78 deletions(-)
delete mode 100644 sysdeps/generic/single-thread.h
delete mode 100644 sysdeps/unix/sysv/linux/aarch64/single-thread.h
delete mode 100644 sysdeps/unix/sysv/linux/arc/single-thread.h
delete mode 100644 sysdeps/unix/sysv/linux/arm/single-thread.h
delete mode 100644 sysdeps/unix/sysv/linux/hppa/single-thread.h
delete mode 100644 sysdeps/unix/sysv/linux/microblaze/single-thread.h
delete mode 100644 sysdeps/unix/sysv/linux/s390/single-thread.h
delete mode 100644 sysdeps/unix/sysv/linux/single-thread.h
delete mode 100644 sysdeps/unix/sysv/linux/x86_64/single-thread.h
Comments
> And move SINGLE_THREAD_P macro to sys/single_threaded.h.
LGTM
Cheers,
Wilco
---
include/sys/single_threaded.h | 13 ++++++--
sysdeps/generic/single-thread.h | 25 ----------------
sysdeps/mach/hurd/sysdep-cancel.h | 5 ----
sysdeps/unix/sysdep.h | 2 +-
.../unix/sysv/linux/aarch64/single-thread.h | 2 --
sysdeps/unix/sysv/linux/arc/single-thread.h | 2 --
sysdeps/unix/sysv/linux/arm/single-thread.h | 2 --
sysdeps/unix/sysv/linux/hppa/single-thread.h | 2 --
.../sysv/linux/microblaze/single-thread.h | 2 --
sysdeps/unix/sysv/linux/s390/single-thread.h | 2 --
sysdeps/unix/sysv/linux/single-thread.h | 30 -------------------
.../unix/sysv/linux/x86_64/single-thread.h | 2 --
12 files changed, 11 insertions(+), 78 deletions(-)
delete mode 100644 sysdeps/generic/single-thread.h
delete mode 100644 sysdeps/unix/sysv/linux/aarch64/single-thread.h
delete mode 100644 sysdeps/unix/sysv/linux/arc/single-thread.h
delete mode 100644 sysdeps/unix/sysv/linux/arm/single-thread.h
delete mode 100644 sysdeps/unix/sysv/linux/hppa/single-thread.h
delete mode 100644 sysdeps/unix/sysv/linux/microblaze/single-thread.h
delete mode 100644 sysdeps/unix/sysv/linux/s390/single-thread.h
delete mode 100644 sysdeps/unix/sysv/linux/single-thread.h
delete mode 100644 sysdeps/unix/sysv/linux/x86_64/single-thread.h
diff --git a/include/sys/single_threaded.h b/include/sys/single_threaded.h
index 2015742be0..f42e40547e 100644
--- a/include/sys/single_threaded.h
+++ b/include/sys/single_threaded.h
@@ -1,6 +1,7 @@
-#include <misc/sys/single_threaded.h>
+#ifndef __ASSEMBLER__
+# include <misc/sys/single_threaded.h>
-#ifndef _ISOMAC
+# ifndef _ISOMAC
libc_hidden_proto_alias (__libc_single_threaded,
__libc_single_threaded_internal);
@@ -9,4 +10,10 @@ libc_hidden_proto_alias (__libc_single_threaded,
# define __libc_single_threaded_internal __libc_single_threaded
#endif
-#endif
+# define SINGLE_THREAD_P (__libc_single_threaded_internal != 0)
+
+# define RTLD_SINGLE_THREAD_P SINGLE_THREAD_P
+
+# endif
+
+#endif /* __ASSEMBLER__ */
diff --git a/sysdeps/generic/single-thread.h b/sysdeps/generic/single-thread.h
deleted file mode 100644
index 7f8222b38a..0000000000
--- a/sysdeps/generic/single-thread.h
+++ /dev/null
@@ -1,25 +0,0 @@
-/* Single thread optimization, generic version.
- Copyright (C) 2019-2022 Free Software Foundation, Inc.
- This file is part of the GNU C Library.
-
- The GNU C Library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Lesser General Public
- License as published by the Free Software Foundation; either
- version 2.1 of the License, or (at your option) any later version.
-
- The GNU C Library is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with the GNU C Library; if not, see
- <https://www.gnu.org/licenses/>. */
-
-#ifndef _SINGLE_THREAD_H
-#define _SINGLE_THREAD_H
-
-#define SINGLE_THREAD_P (0)
-#define RTLD_SINGLE_THREAD_P (0)
-
-#endif /* _SINGLE_THREAD_H */
diff --git a/sysdeps/mach/hurd/sysdep-cancel.h b/sysdeps/mach/hurd/sysdep-cancel.h
index 669c17151a..9311367ab9 100644
--- a/sysdeps/mach/hurd/sysdep-cancel.h
+++ b/sysdeps/mach/hurd/sysdep-cancel.h
@@ -6,11 +6,6 @@ void __pthread_disable_asynccancel (int oldtype);
#pragma weak __pthread_enable_asynccancel
#pragma weak __pthread_disable_asynccancel
-/* Always multi-thread (since there's at least the sig handler), but no
- handling enabled. */
-#define SINGLE_THREAD_P (0)
-#define RTLD_SINGLE_THREAD_P (0)
-
#define LIBC_CANCEL_ASYNC() ({ \
int __cancel_oldtype = 0; \
if (__pthread_enable_asynccancel) \
diff --git a/sysdeps/unix/sysdep.h b/sysdeps/unix/sysdep.h
index a1d9df4c73..a8abecb92b 100644
--- a/sysdeps/unix/sysdep.h
+++ b/sysdeps/unix/sysdep.h
@@ -16,7 +16,7 @@
<https://www.gnu.org/licenses/>. */
#include <sysdeps/generic/sysdep.h>
-#include <single-thread.h>
+#include <sys/single_threaded.h>
#include <sys/syscall.h>
#define HAVE_SYSCALLS
diff --git a/sysdeps/unix/sysv/linux/aarch64/single-thread.h b/sysdeps/unix/sysv/linux/aarch64/single-thread.h
deleted file mode 100644
index a5d3a2aaf4..0000000000
--- a/sysdeps/unix/sysv/linux/aarch64/single-thread.h
+++ /dev/null
@@ -1,2 +0,0 @@
-#define SINGLE_THREAD_BY_GLOBAL
-#include_next <single-thread.h>
diff --git a/sysdeps/unix/sysv/linux/arc/single-thread.h b/sysdeps/unix/sysv/linux/arc/single-thread.h
deleted file mode 100644
index a5d3a2aaf4..0000000000
--- a/sysdeps/unix/sysv/linux/arc/single-thread.h
+++ /dev/null
@@ -1,2 +0,0 @@
-#define SINGLE_THREAD_BY_GLOBAL
-#include_next <single-thread.h>
diff --git a/sysdeps/unix/sysv/linux/arm/single-thread.h b/sysdeps/unix/sysv/linux/arm/single-thread.h
deleted file mode 100644
index a5d3a2aaf4..0000000000
--- a/sysdeps/unix/sysv/linux/arm/single-thread.h
+++ /dev/null
@@ -1,2 +0,0 @@
-#define SINGLE_THREAD_BY_GLOBAL
-#include_next <single-thread.h>
diff --git a/sysdeps/unix/sysv/linux/hppa/single-thread.h b/sysdeps/unix/sysv/linux/hppa/single-thread.h
deleted file mode 100644
index a5d3a2aaf4..0000000000
--- a/sysdeps/unix/sysv/linux/hppa/single-thread.h
+++ /dev/null
@@ -1,2 +0,0 @@
-#define SINGLE_THREAD_BY_GLOBAL
-#include_next <single-thread.h>
diff --git a/sysdeps/unix/sysv/linux/microblaze/single-thread.h b/sysdeps/unix/sysv/linux/microblaze/single-thread.h
deleted file mode 100644
index a5d3a2aaf4..0000000000
--- a/sysdeps/unix/sysv/linux/microblaze/single-thread.h
+++ /dev/null
@@ -1,2 +0,0 @@
-#define SINGLE_THREAD_BY_GLOBAL
-#include_next <single-thread.h>
diff --git a/sysdeps/unix/sysv/linux/s390/single-thread.h b/sysdeps/unix/sysv/linux/s390/single-thread.h
deleted file mode 100644
index a5d3a2aaf4..0000000000
--- a/sysdeps/unix/sysv/linux/s390/single-thread.h
+++ /dev/null
@@ -1,2 +0,0 @@
-#define SINGLE_THREAD_BY_GLOBAL
-#include_next <single-thread.h>
diff --git a/sysdeps/unix/sysv/linux/single-thread.h b/sysdeps/unix/sysv/linux/single-thread.h
deleted file mode 100644
index 2099848cf3..0000000000
--- a/sysdeps/unix/sysv/linux/single-thread.h
+++ /dev/null
@@ -1,30 +0,0 @@
-/* Single thread optimization, Linux version.
- Copyright (C) 2019-2022 Free Software Foundation, Inc.
- This file is part of the GNU C Library.
-
- The GNU C Library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Lesser General Public
- License as published by the Free Software Foundation; either
- version 2.1 of the License, or (at your option) any later version.
-
- The GNU C Library is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with the GNU C Library; if not, see
- <https://www.gnu.org/licenses/>. */
-
-#ifndef _SINGLE_THREAD_H
-#define _SINGLE_THREAD_H
-
-#ifndef __ASSEMBLER__
-# include <sys/single_threaded.h>
-#endif
-
-#define SINGLE_THREAD_P (__libc_single_threaded_internal != 0)
-
-#define RTLD_SINGLE_THREAD_P SINGLE_THREAD_P
-
-#endif /* _SINGLE_THREAD_H */
diff --git a/sysdeps/unix/sysv/linux/x86_64/single-thread.h b/sysdeps/unix/sysv/linux/x86_64/single-thread.h
deleted file mode 100644
index a5d3a2aaf4..0000000000
--- a/sysdeps/unix/sysv/linux/x86_64/single-thread.h
+++ /dev/null
@@ -1,2 +0,0 @@
-#define SINGLE_THREAD_BY_GLOBAL
-#include_next <single-thread.h>
@@ -1,6 +1,7 @@
-#include <misc/sys/single_threaded.h>
+#ifndef __ASSEMBLER__
+# include <misc/sys/single_threaded.h>
-#ifndef _ISOMAC
+# ifndef _ISOMAC
libc_hidden_proto_alias (__libc_single_threaded,
__libc_single_threaded_internal);
@@ -9,4 +10,10 @@ libc_hidden_proto_alias (__libc_single_threaded,
# define __libc_single_threaded_internal __libc_single_threaded
#endif
-#endif
+# define SINGLE_THREAD_P (__libc_single_threaded_internal != 0)
+
+# define RTLD_SINGLE_THREAD_P SINGLE_THREAD_P
+
+# endif
+
+#endif /* __ASSEMBLER__ */
deleted file mode 100644
@@ -1,25 +0,0 @@
-/* Single thread optimization, generic version.
- Copyright (C) 2019-2022 Free Software Foundation, Inc.
- This file is part of the GNU C Library.
-
- The GNU C Library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Lesser General Public
- License as published by the Free Software Foundation; either
- version 2.1 of the License, or (at your option) any later version.
-
- The GNU C Library is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with the GNU C Library; if not, see
- <https://www.gnu.org/licenses/>. */
-
-#ifndef _SINGLE_THREAD_H
-#define _SINGLE_THREAD_H
-
-#define SINGLE_THREAD_P (0)
-#define RTLD_SINGLE_THREAD_P (0)
-
-#endif /* _SINGLE_THREAD_H */
@@ -6,11 +6,6 @@ void __pthread_disable_asynccancel (int oldtype);
#pragma weak __pthread_enable_asynccancel
#pragma weak __pthread_disable_asynccancel
-/* Always multi-thread (since there's at least the sig handler), but no
- handling enabled. */
-#define SINGLE_THREAD_P (0)
-#define RTLD_SINGLE_THREAD_P (0)
-
#define LIBC_CANCEL_ASYNC() ({ \
int __cancel_oldtype = 0; \
if (__pthread_enable_asynccancel) \
@@ -16,7 +16,7 @@
<https://www.gnu.org/licenses/>. */
#include <sysdeps/generic/sysdep.h>
-#include <single-thread.h>
+#include <sys/single_threaded.h>
#include <sys/syscall.h>
#define HAVE_SYSCALLS
deleted file mode 100644
@@ -1,2 +0,0 @@
-#define SINGLE_THREAD_BY_GLOBAL
-#include_next <single-thread.h>
deleted file mode 100644
@@ -1,2 +0,0 @@
-#define SINGLE_THREAD_BY_GLOBAL
-#include_next <single-thread.h>
deleted file mode 100644
@@ -1,2 +0,0 @@
-#define SINGLE_THREAD_BY_GLOBAL
-#include_next <single-thread.h>
deleted file mode 100644
@@ -1,2 +0,0 @@
-#define SINGLE_THREAD_BY_GLOBAL
-#include_next <single-thread.h>
deleted file mode 100644
@@ -1,2 +0,0 @@
-#define SINGLE_THREAD_BY_GLOBAL
-#include_next <single-thread.h>
deleted file mode 100644
@@ -1,2 +0,0 @@
-#define SINGLE_THREAD_BY_GLOBAL
-#include_next <single-thread.h>
deleted file mode 100644
@@ -1,30 +0,0 @@
-/* Single thread optimization, Linux version.
- Copyright (C) 2019-2022 Free Software Foundation, Inc.
- This file is part of the GNU C Library.
-
- The GNU C Library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Lesser General Public
- License as published by the Free Software Foundation; either
- version 2.1 of the License, or (at your option) any later version.
-
- The GNU C Library is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with the GNU C Library; if not, see
- <https://www.gnu.org/licenses/>. */
-
-#ifndef _SINGLE_THREAD_H
-#define _SINGLE_THREAD_H
-
-#ifndef __ASSEMBLER__
-# include <sys/single_threaded.h>
-#endif
-
-#define SINGLE_THREAD_P (__libc_single_threaded_internal != 0)
-
-#define RTLD_SINGLE_THREAD_P SINGLE_THREAD_P
-
-#endif /* _SINGLE_THREAD_H */
deleted file mode 100644
@@ -1,2 +0,0 @@
-#define SINGLE_THREAD_BY_GLOBAL
-#include_next <single-thread.h>