From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from elaine.keithp.com (home.keithp.com [63.227.221.253]) by sourceware.org (Postfix) with ESMTPS id 27F84386188D; Mon, 7 Dec 2020 20:36:38 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 27F84386188D Received: from localhost (localhost [127.0.0.1]) by elaine.keithp.com (Postfix) with ESMTP id 899CC3F2E1F1; Mon, 7 Dec 2020 12:36:36 -0800 (PST) X-Virus-Scanned: Debian amavisd-new at keithp.com Received: from elaine.keithp.com ([127.0.0.1]) by localhost (elaine.keithp.com [127.0.0.1]) (amavisd-new, port 10024) with LMTP id Ck4H44LdgR6n; Mon, 7 Dec 2020 12:36:34 -0800 (PST) Received: from keithp.com (koto.keithp.com [10.0.0.2]) by elaine.keithp.com (Postfix) with ESMTPSA id E511E3F2E1EB; Mon, 7 Dec 2020 12:36:33 -0800 (PST) Received: by keithp.com (Postfix, from userid 1000) id BC6F415820DB; Mon, 7 Dec 2020 12:36:33 -0800 (PST) From: Keith Packard To: Jonathan Wakely Cc: libstdc++@gcc.gnu.org, gcc-patches@gcc.gnu.org Subject: Re: [PATCH 1/2] libstdc++: Add --enable-pure-stdio-libstdcxx option In-Reply-To: <20201207185501.GA4100714@redhat.com> References: <20201207183927.3275768-1-keithp@keithp.com> <20201207183927.3275768-2-keithp@keithp.com> <20201207185501.GA4100714@redhat.com> Date: Mon, 07 Dec 2020 12:36:33 -0800 Message-ID: <87y2i98ib2.fsf@keithp.com> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" X-Spam-Status: No, score=-4.8 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: libstdc++@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libstdc++ mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 07 Dec 2020 20:36:39 -0000 --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Jonathan Wakely writes: > GCC changelog files are autogenerated now, so patches should not touch > them. Just include the ChangeLog entry in the Git commit log (which > will usually end up being quoted in the patch and/or the email body of > the mail to gcc-patches). Awesome. > I think the right way to do this (or at least, the way that was > intended when basic_file_stdio.cc was added) is to provide a new file > and change GLIBCXX_ENABLE_CSTDIO in acinclude.m4 to use that new file. > > The two biggest downsides of that are that it duplicates a lot of the > file (because the diffs for your changes are small) and that the > correct name for your new file is already taken! I can definitely see a reason to use a separate file when implementing the basic_file interface on top of something other than stdio, but this patch doesn't do that -- it only changes the interaction between basic_file and stdio in a few places. I think it makes the best long-term sense to leave everything in basic_file_stdio.cc and avoid having the two implementations diverge in the future. > However, it's rather late in the GCC 11 process to make a change like > that (even though it's really just renaming some files). Would you be > OK waiting until after GCC 11 is released (in 4-5 months) to do it > "properly"? Is this blocking something that would require doing it > sooner? This patch enables the use of C++ with picolibc, a libc designed for 32- and 64- bit embedded systems. Right now, I'm working on getting picolibc support integrated into Zephyr, which uses toolchains build by crosstool-ng. I've gotten picolibc support merged to crosstool-ng, but the Zephyr developers are interested in having a single toolchain support three different libc implementations (newlib, newlib-nano and picolibc), but that's blocked on having C++ support available in all three libraries. So, you're at the bottom of my current dependency graph :-) I don't particularly need this released in gcc, but I would like to get patches reviewed and the general approach agreed on so that I can feel more confident in preparing patches to be applied to gcc in crosstool-ng itself. Once that's done, I'll also be able to release new Debian packages of GCC for embedded ARM and RISC-V and have those include suitable patches so that we can support embedded C++ development there too.=20 =2D-=20 =2Dkeith --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEw4O3eCVWE9/bQJ2R2yIaaQAAABEFAl/OklEACgkQ2yIaaQAA ABEtFg//WXPCKL6MWpRWfGqOAxzJs2SFFD76bA3Bnsm4kBNGWOhK/NoMAvhjPBa1 Itg8VYtjQYfBlODS+U7T1eZnygk0LcTuthsz6cBFWq+WZtP5Lbk0jQp4IoB5SOzo BIz30Gv/cyZwPApiWNe1viZjUHYlBSa00Fd5lsi8IDBlSIlBN/k9qoc8PUuv8FAB 5NEvB+qN5piV5uPbRmQPD1Wo6l6HXgyDA0jXtkyvi8Y86vfhNdtDDXtWTMlKGGmK 32IDRMmZKtsrlyeGcoAcyKXOUzkdcMdvqFzMdPUjjqRY7o0tYoHDV+/vnkJTAcNW 57mZOVUzDsiWftaIYsJYAwG4dKgINszuGwN7Jq5vTmNKIcBxXTx/ZFwqCvoAFXaF EoMGyYPSBCMAyHqlVkVeV6Bvp7KewpaDsvl1ishGXR+2ZL9TjUfVBhQeoCDXSZ+2 ePeHikQ/7j8F2POtPEPn/cbpGhCXFCP0G/oNXjXQKGqhLM5M9ws+m+bWB3OYfje2 YM55dAOFB3VRfOzQoUzpCdHRF7DxmEQ43gVQIMROi/KMqFkbyrQ3ETlgI5uCXMcM Apf7edHIxSqHWJhlkt3cxP2wtxkF1vFSzG14VcKRMCuweb/lmJ1uEq7kceDeEni5 cZqdjAJtFl4geyVUOZlKvzDC3wW3FeXsRrbDeYkz0q0+2TMPbwg= =SR9n -----END PGP SIGNATURE----- --=-=-=--