From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id NjPaOlIi2mDiygAAgWs5BA (envelope-from ) for ; Mon, 28 Jun 2021 21:26:10 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id aPrBNVIi2mBIEQAAbx9fmQ (envelope-from ) for ; Mon, 28 Jun 2021 19:26:10 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id B3CB2109D3 for ; Mon, 28 Jun 2021 21:26:10 +0200 (CEST) Received: from localhost ([::1]:34388 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lxwtV-0007T4-Qi for larch@yhetil.org; Mon, 28 Jun 2021 15:26:09 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:52276) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lxwtO-0007SM-Rr for guix-patches@gnu.org; Mon, 28 Jun 2021 15:26:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:41079) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lxwtO-0000YW-Jr for guix-patches@gnu.org; Mon, 28 Jun 2021 15:26:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1lxwtO-000470-H8 for guix-patches@gnu.org; Mon, 28 Jun 2021 15:26:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#49019] [PATCH 0/1] gnu: Add gccgo-10. Resent-From: Efraim Flashner Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 28 Jun 2021 19:26:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 49019 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: iskarian@mgsn.dev Cc: 49019@debbugs.gnu.org Received: via spool by 49019-submit@debbugs.gnu.org id=B49019.162490830715712 (code B ref 49019); Mon, 28 Jun 2021 19:26:02 +0000 Received: (at 49019) by debbugs.gnu.org; 28 Jun 2021 19:25:07 +0000 Received: from localhost ([127.0.0.1]:52617 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lxwsR-00044z-HE for submit@debbugs.gnu.org; Mon, 28 Jun 2021 15:25:07 -0400 Received: from flashner.co.il ([178.62.234.194]:53098) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lxwsP-000445-Kv for 49019@debbugs.gnu.org; Mon, 28 Jun 2021 15:25:02 -0400 Received: from localhost (unknown [31.210.177.125]) by flashner.co.il (Postfix) with ESMTPSA id E425A40190; Mon, 28 Jun 2021 19:24:55 +0000 (UTC) Date: Mon, 28 Jun 2021 22:22:33 +0300 From: Efraim Flashner Message-ID: Mail-Followup-To: Efraim Flashner , iskarian@mgsn.dev, 49019@debbugs.gnu.org References: <20210614041653.3085-1-iskarian@mgsn.dev> <96de532e108afa2cf35ae45a87053e19@mgsn.dev> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="BTTHglFNmE0oc5fI" Content-Disposition: inline In-Reply-To: <96de532e108afa2cf35ae45a87053e19@mgsn.dev> X-PGP-Key-ID: 0x41AAE7DCCA3D8351 X-PGP-Key: https://flashner.co.il/~efraim/efraim_flashner.asc X-PGP-Fingerprint: A28B F40C 3E55 1372 662D 14F7 41AA E7DC CA3D 8351 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Migadu-Flow: FLOW_IN X-Migadu-Spam-Score: -4.00 Authentication-Results: aspmx1.migadu.com; none X-Migadu-Queue-Id: B3CB2109D3 X-Spam-Score: -4.00 X-Migadu-Scanner: scn0.migadu.com X-TUID: lWqnGLXvWTRk --BTTHglFNmE0oc5fI Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Jun 21, 2021 at 09:32:22PM +0000, iskarian@mgsn.dev wrote: > Thanks for taking a look at this, Efraim! >=20 > June 21, 2021 6:25 AM, "Efraim Flashner" wrote: >=20 > > On Sun, Jun 13, 2021 at 09:16:53PM -0700, Sarah Morgensen via Guix-patc= hes via wrote: > >=20 > >> The primary goal for adding gccgo is to bootstrap the go compiler for = arches > >> that aren't supported by go 1.4. I believe the major one to support he= re is > >> powerpc64le, but I am unsure of current arch usage. A secondary goal i= s to > >> provide a gccgo-toolchain, as gccgo may provide advantages over gc in = time. > >>=20 > >> I have successfully built gccgo 9, 10 and 11 for x86-64. I additionall= y tested > >> gcc 10 using `make check-go`. There are two minor test failures: > >>=20 > >> 1. index0-out.go, previously reported upstream [0] > >> 2. pprof (TestConvertCPUProfile/TestConvertMemProfile) > >>=20 > >> (I have not yet been able to deterine whether the pprof failures are a= n upstream > >> bug or a Guix bug. Should I send details to bug-guix?) > >=20 > > I wouldn't worry about the test failures. > >=20 > >> Finally, the regex update in [1] is implemented in CUSTOM-GCC-GCCGO ra= ther than > >> CUSTOM-GCC to avoid rebuilding 2k+ gfortran packages, and CUSTOM-GCC-G= CCGO > >> should be removed after the change is in master. > >=20 > > Makes sense > >=20 > >> [0] https://issues.guix.gnu.org/49010 > >> [1] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D87589 > >>=20 > >> Sarah Morgensen (1): > >> gnu: Add gccgo-10. > >>=20 > >> gnu/packages/gcc.scm | 77 ++++++++++++++++++++++++++++++++++++++++++++ > >> 1 file changed, 77 insertions(+) > >>=20 > >> -- > >> 2.31.1 > >=20 > > I threw together a quick gccgo-toolchain package and tried using that to > > build keybase and syncthing. One of the errors I came across was: > > /home/efraim/go/pkg/mod/golang.org/x/sys@v0.0.0-20200922070232-aee5d888= a860/unix/gccgo.go:50: > > undefined reference to `gccgoRealSyscallNoError' and also > > github.com/minio/sha256-simd@v0.1.1 didn't like the assembly in the > > package. >=20 > The assembly problem is (unfortunately) a known limitation of gccgo. The = gc and > gccgo compilers use different asm syntax, so many extant go programs cann= ot > currently be compiled with gccgo alone. There are also other limitations = with > the go tools provided by gccgo, as only a subset have been implemented. >=20 > However, I have successfully built go-1.16 with gccgo with a few tweaks. = (Most > dependent packages build with no modification or with a version bump, and= I > have minimal patches for the handful of others. Docker will have to be up= dated > to work with go-1.16, which will likely be out of my depth.) I plan to sh= are > a patchset for this soon. >=20 > As for x/sys: most likely updating the module dependency will solve it. I= see > x/sys has had some gccgo related commits since that version was released. Sounds good. > > It's definitely possible that I'm missing some flag to tell go that I'm > > really using gccgo. Or that it should be built with binutils-gold. >=20 > I must admit that I had not even thought about whether gold might be > necessary. I really am out of my depth on this one. I see that you author= ed > the patch for go@1.14 to use gold on armhf and aarch64, so you likely know > more about this than me! Presumably that was in regards to [0] and [1]? That one's come forward with a couple of go versions. Perhaps it'd be best to add it unconditionally, or at least to switch the logic and only skip it on x86_64 and i686. > Other than that, the main motivation for using gold seems to be the suppo= rt for > split-stack, which allows the use of many more goroutines before running = out of > stack space [2]. Replacing GNU ld (`./configure --with-ld=3D...') as [2] = suggests > may introduce bugs... It appears that in at least one case (ppc64) gccgo > prefers gold even if gcc was not built solely with it [3]. Unfortunately,= adding > gold as an optional linker would add ~75MiB to closure size... >=20 > I'm not sure what the best way forward is, here. WDYT? It's not a lot of extra closure size, given just how large the go package itself is. I think we leave it as-is for now and add change it up later if necessary. >=20 > [0]: https://github.com/golang/go/issues/15696 > [1]: https://sourceware.org/bugzilla/show_bug.cgi?id=3D19962 > [2]: https://golang.org/doc/install/gccgo#Gold > [3]: https://github.com/gcc-mirror/gcc/commit/402565b61f9783473472fcfd729= efa8c1e355d2b --=20 Efraim Flashner =D7=90=D7=A4=D7=A8=D7=99=D7=9D = =D7=A4=D7=9C=D7=A9=D7=A0=D7=A8 GPG key =3D A28B F40C 3E55 1372 662D 14F7 41AA E7DC CA3D 8351 Confidentiality cannot be guaranteed on emails sent or received unencrypted --BTTHglFNmE0oc5fI Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEoov0DD5VE3JmLRT3Qarn3Mo9g1EFAmDaIXkACgkQQarn3Mo9 g1HTWQ/+MffO+XFp1KLd1L6zSHAsqdHdjFysOUs9ip5fQHf7cqJMctEOep9lAoN0 KOBso3b42rA28NLqzGarxZVOLrOiU7XKaGSTV7yS1oRf1OUnJM0fDsXhlw9+gDIR C49UIyIPELuaR2FFsp4ZcIW8ZmR/5dZQUwlSYc18/iCj4YpGxaBLp4a2uVOrRflE eFn2qn4UMWij+o0tuUaFZGmRz1I67ZiivT5/jc30Omjm9dNthxHm7u9d+8/gJiWE G3AfRNfjFEUaX3S1NWMREglHdfSTXkYoYOEE5oKyJBn74sr+KWvKJjCWUQHM7fZI VENC12/b90w8228Ip/QUGb+W5dAeSjPwx3ZSQkXSjvB0gC1FZa/Gf6fgaZBGyfBc RYb7MY9US1Ks54Hrx1YXq6PRlKHVLr8JfJtd5z83Pf4bkuxy9QPVLpYvw3bLMDM6 QghHUECPgTvu3vNN7IhHqG2y15KXFQ87VysK1FwZsFmNbpisGWeUSQaWdxMvSHhM JRnwnsVrUehYcjDYT4qXn8SgI6gGc/BnUXCbyEmPbax3EObNJtGw+rIUGLUOMHJa tFyUQsNYQWu7aARbbwM6ZncbgM7z815ljf4GXSblbPqSQwfLY90p1jVgdnPhu/Eb 39xeOyw7UIPYISpRY/amT5PBkaNGF60Jb2q5keTSdirBV2a3GNs= =F0JH -----END PGP SIGNATURE----- --BTTHglFNmE0oc5fI--