* committed: Always assume NetBSD support pthreads
@ 2017-07-09 4:44 Krister Walfridsson
0 siblings, 0 replies; only message in thread
From: Krister Walfridsson @ 2017-07-09 4:44 UTC (permalink / raw)
To: gcc-patches
[-- Attachment #1: Type: TEXT/PLAIN, Size: 447 bytes --]
I have committed the attached patch to remove checks for obsolete NetBSD
releases from the 1990s that do not support pthreads.
Bootstrapped and tested on i386-unknown-netbsdelf6.1 and
x86_64-unknown-netbsd6.1.
/Krister
2017-07-09 Krister Walfridsson <krister.walfridsson@gmail.com>
* config.gcc (*-*-netbsd*): Remove check for NetBSD versions not
supporting pthreds.
* config/netbsd.h (NETBSD_LIBGCC_SPEC): Always enable pthreads.
[-- Attachment #2: Type: TEXT/PLAIN, Size: 1728 bytes --]
Index: gcc/config.gcc
===================================================================
--- gcc/config.gcc (revision 250080)
+++ gcc/config.gcc (revision 250081)
@@ -794,22 +794,8 @@
gas=yes
gnu_ld=yes
use_gcc_stdint=wrap
-
- # NetBSD 2.0 and later get POSIX threads enabled by default.
- # Allow them to be explicitly enabled on any other version.
case ${enable_threads} in
- "")
- case ${target} in
- *-*-netbsd[2-9]* | *-*-netbsdelf[2-9]*)
- thread_file='posix'
- tm_defines="${tm_defines} NETBSD_ENABLE_PTHREADS"
- ;;
- esac
- ;;
- yes | posix)
- thread_file='posix'
- tm_defines="${tm_defines} NETBSD_ENABLE_PTHREADS"
- ;;
+ "" | yes | posix) thread_file='posix' ;;
esac
# NetBSD 2.0 and later provide __cxa_atexit(), which we use by
Index: gcc/config/netbsd.h
===================================================================
--- gcc/config/netbsd.h (revision 250080)
+++ gcc/config/netbsd.h (revision 250081)
@@ -84,7 +84,6 @@
FIXME: Could eliminate the duplication here if we were allowed to
use string concatenation. */
-#ifdef NETBSD_ENABLE_PTHREADS
#define NETBSD_LIB_SPEC \
"%{pthread: \
%{!p: \
@@ -103,21 +102,6 @@
%{!pg:-lc}} \
%{p:-lc_p} \
%{pg:-lc_p}}}"
-#else
-#define NETBSD_LIB_SPEC \
- "%{posix: \
- %{!p: \
- %{!pg:-lposix}} \
- %{p:-lposix_p} \
- %{pg:-lposix_p}} \
- %{shared:-lc} \
- %{!shared: \
- %{!symbolic: \
- %{!p: \
- %{!pg:-lc}} \
- %{p:-lc_p} \
- %{pg:-lc_p}}}"
-#endif
#undef LIB_SPEC
#define LIB_SPEC NETBSD_LIB_SPEC
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2017-07-09 4:44 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-07-09 4:44 committed: Always assume NetBSD support pthreads Krister Walfridsson
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).