From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) by sourceware.org (Postfix) with ESMTP id C3BBD3858D1E for ; Fri, 11 Feb 2022 10:09:52 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org C3BBD3858D1E Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gentoo.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gentoo.org Received: by smtp.gentoo.org (Postfix, from userid 559) id 0B40D342E4E; Fri, 11 Feb 2022 10:09:51 +0000 (UTC) Date: Fri, 11 Feb 2022 05:09:54 -0500 From: Mike Frysinger To: C Howland Cc: newlib@sourceware.org Subject: Re: [PATCH] newlib: remove unused fenv flags Message-ID: Mail-Followup-To: C Howland , newlib@sourceware.org References: <20220210055347.24825-1-vapier@gentoo.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="T2vV2cF2gb1Qtbly" Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-5.5 required=5.0 tests=BAYES_00, KAM_DMARC_STATUS, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, SPF_HELO_PASS, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: newlib@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Newlib mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 Feb 2022 10:09:55 -0000 --T2vV2cF2gb1Qtbly Content-Type: text/plain; charset=utf-8 Content-Disposition: inline On 10 Feb 2022 14:18, C Howland wrote: > First, would be if a machine directory can override just some files > from the main--as if viewpathed--and this can also apply to the makefile. > (Does the machine directory totally replace the main branch directory, or > can it be supplemental? My impression was a viewpath model, which can be > supplementary or replace all.) If I'm wrong about this, no problem, no > objection for this specific reason. assuming "viewpathed" means "VPATH in the makefile", then no, that's not how newlib works. that is how glibc works, so maybe you're thinking of that. newlib compiles all objects in all subdirs in isolation. it then assembles the final libm.a/libc.a in a specific order (with the machine dir last). so it adds fenv/*.o to libm.a by basename, then replaces any existing ones with machine/$arch/*.o. > The second is if the main branch is intended to also be a template for > new machine directories. The C part of it definitely is, but the makefile > does not necessarily fall into that category. So I'll turn that into a > question: if the main branch makefile does not serve as a template for the > machine directories, where would that be? That is, while these arguments > are superfluous in the main dir, should they remain in comments as an aid > to machine developers, in the same manner in which the source code is > annotated? (It's not so much these specific arguments, themselves, but > having an example how ones like this would be added. These particular ones > are reasonable for serving that purpose, however.) The real makefile seems > the best place for this. We could have Makefile.template, or something > along those lines, but the real one is forced to be valid by being used, > while maintaining a separate template would be additional maintenance work. > So if I'm wrong about the viewpathing model, a suggestion: rather > than deleting the lines, comment them out and add some comment text > suitable for a template. If you're amenable to this approach and would > like, I (or possibly Joel if he's interested) could contribute suggested > comments for you to use. this isn't specific to fenv/. you can make this argument against any of the subdirs. even then, the use of -fbuiltin & -fno-math-errno kind of seem like the opposite of what you're arguing. -fno-math-errno shouldn't be used in general as it is an optimization that can break correctness wrt IEEE standards. -fbuiltin probably shouldn't be applied to entire subdirs without strict review since it allows the compiler to rewrite calls that assume C library behavior, but the C library might be violating those assumptions specifically as part of its implementation. -mike --T2vV2cF2gb1Qtbly Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEEuQK1JxMl+JKsJRrUQWM7n+g39YEFAmIGNfIACgkQQWM7n+g3 9YE34A/+JmrYgHbnCrAnR0d0OjGJghxawfDx6jz7hgeceXKfRFc8isg1efzQ487n Gj/U3VO9fUzEYRenKXZ+KcnDgWa3oaRH4XOMqZ5Dmcc4WK6jfIlr28rTdXEKVNLY uUY56KxORTevLnMYJV2EPIe9PC3u0MRwbVbU64DpBK9ZbEk4ZAarOxItcpBMj0t5 9rxaNFk1v9lIcGAqtE+YInHEOqJajr5dRQNYBd7z55AT9zQVgPuV9feCTvF30Dmm SNqX4+AGVwFV27OAcv9O4ujIvbLO60aInQO3jg7Devbv50rAqRsGBCxla62LY+z8 REDa96AOPLjtkljyXMLBANPy9Zu0EOItz3Coq/wn3HvRx0lCk1obbtylf3NBL+dV OMPhUF9q+Y6Bn1GqMy7SMNFvXt3M+thg4wgsjOsV+0rkTn6p1Pb9OC6F9dbaBV+h hhIYn1xtSVnDvZTO+FDbwPw+uV7EiqCwhngTYdrfAwVSDG4hcC8uumwPChKP3yot W4oTYhTxULrM5sWFBZhDP4DfbXwlgD1st2IqNq1ZE31A33M+edoY9gwXziiYz2Hl 0Bndw0YCAGkBeteW7o/fi/tVovEx734qizSVGpJ72Qk6aVrKtAvdSw9wGADh59NF fcB/KHqWfKjy1mn7NwfI02o9I62WqzmRVsnVL9ZDrbEIDDVbwwI= =qbTE -----END PGP SIGNATURE----- --T2vV2cF2gb1Qtbly--