From nobody Wed May 04 19:53:17 2022 X-Original-To: freebsd-current@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 59F991AA9DA1 for ; Wed, 4 May 2022 19:53:25 +0000 (UTC) (envelope-from sgk@troutmask.apl.washington.edu) Received: from troutmask.apl.washington.edu (troutmask.apl.washington.edu [128.95.76.21]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "troutmask", Issuer "troutmask" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4KtnZD105Bz3Q8N; Wed, 4 May 2022 19:53:24 +0000 (UTC) (envelope-from sgk@troutmask.apl.washington.edu) Received: from troutmask.apl.washington.edu (localhost [127.0.0.1]) by troutmask.apl.washington.edu (8.16.1/8.16.1) with ESMTPS id 244JrHN7024947 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NO); Wed, 4 May 2022 12:53:17 -0700 (PDT) (envelope-from sgk@troutmask.apl.washington.edu) Received: (from sgk@localhost) by troutmask.apl.washington.edu (8.16.1/8.16.1/Submit) id 244JrHmO024946; Wed, 4 May 2022 12:53:17 -0700 (PDT) (envelope-from sgk) Date: Wed, 4 May 2022 12:53:17 -0700 From: Steve Kargl To: John Baldwin Cc: Ed Maste , FreeBSD Current Subject: Re: Profiled libraries on freebsd-current Message-ID: Reply-To: sgk@troutmask.apl.washington.edu References: <80e38cf3-0d53-fce6-76e6-936c47d95c91@FreeBSD.org> List-Id: Discussions about the use of FreeBSD-current List-Archive: https://lists.freebsd.org/archives/freebsd-current List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-current@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <80e38cf3-0d53-fce6-76e6-936c47d95c91@FreeBSD.org> X-Rspamd-Queue-Id: 4KtnZD105Bz3Q8N X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=fail reason="No valid SPF, No valid DKIM" header.from=washington.edu (policy=none); spf=none (mx1.freebsd.org: domain of sgk@troutmask.apl.washington.edu has no SPF policy when checking 128.95.76.21) smtp.mailfrom=sgk@troutmask.apl.washington.edu X-Spamd-Result: default: False [-2.65 / 15.00]; HAS_REPLYTO(0.00)[sgk@troutmask.apl.washington.edu]; ARC_NA(0.00)[]; MID_RHS_MATCH_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000]; MIME_GOOD(-0.10)[text/plain]; REPLYTO_ADDR_EQ_FROM(0.00)[]; NEURAL_HAM_MEDIUM(-0.68)[-0.678]; TO_DN_ALL(0.00)[]; NEURAL_HAM_SHORT(-0.97)[-0.974]; MLMMJ_DEST(0.00)[freebsd-current]; R_SPF_NA(0.00)[no SPF record]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:73, ipnet:128.95.0.0/16, country:US]; RCVD_COUNT_TWO(0.00)[2]; RCVD_TLS_ALL(0.00)[]; DMARC_POLICY_SOFTFAIL(0.10)[washington.edu : No valid SPF, No valid DKIM,none] X-ThisMailContainsUnwantedMimeParts: N On Wed, May 04, 2022 at 11:12:55AM -0700, John Baldwin wrote: > On 5/2/22 10:37 AM, Steve Kargl wrote: > > On Mon, May 02, 2022 at 12:32:25PM -0400, Ed Maste wrote: > > > On Sun, 1 May 2022 at 11:54, Steve Kargl > > > wrote: > > > > > > > > diff --git a/gcc/config/freebsd-spec.h b/gcc/config/freebsd-spec.h > > > > index 594487829b5..1e8ab2e1827 100644 > > > > --- a/gcc/config/freebsd-spec.h > > > > +++ b/gcc/config/freebsd-spec.h > > > > @@ -93,14 +93,22 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see > > > > (similar to the default, except no -lg, and no -p). */ > > > > > > > > #ifdef FBSD_NO_THREADS > > > > > > I wonder if we can simplify things now, and remove this > > > `FBSD_NO_THREADS` case. I didn't see anything similar in other GCC > > > targets I looked at. > > > > That I don't know. FBSD_NO_THREADS is defined in freebsd-nthr.h. > > In fact, it's the only thing in that header (except copyright > > broilerplate). freebsd-nthr.h only appears in config.gcc and > > seems to only get added to the build if someone runs configure > > with --enable-threads=no. Looking at my last config.log for > > gcc trunk, I see "Thread model: posix", which appears to be > > the default case or if someone does --enable-threads=yes or > > --enable-threads=posix. So, I suppose it comes down to > > two questions: (1) is libpthread.* available on all supported > > targets and versions? (2) does anyone build gcc without > > threads support? > > libpthread is available on all supported architectures on all > supported versions. libthr has been the default threading library > since 7.0 and the only supported library since 8.0. In GDB I just > assume libthr style threads, and I think GCC can safely do the > same. > I don't know the entire FreeBSD ecosystem. Do people use FreeBSD on embedded systems (e.g., nanobsd) where libthr may be stripped out? Thus, --enable-threads=no is needed. gcc/config/freebsd-nthr.h was committed on May 22, 2001. There have been no changes to the file other than cosmetic ones (e.g., updating copyright notice). gcc/config/freebsd-spec.h has had a number of changes. Someone with a better understanding of the spec file will need to clean that up. -- Steve