From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <bug-guix-bounces+larch=yhetil.org@gnu.org>
Received: from mp1.migadu.com ([2001:41d0:303:e16b::])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits))
	by ms13.migadu.com with LMTPS
	id oAAEH7lHU2fRJAAA62LTzQ:P1
	(envelope-from <bug-guix-bounces+larch=yhetil.org@gnu.org>)
	for <larch@yhetil.org>; Fri, 06 Dec 2024 18:51:37 +0000
Received: from aspmx1.migadu.com ([2001:41d0:303:e16b::])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits))
	by mp1.migadu.com with LMTPS
	id oAAEH7lHU2fRJAAA62LTzQ
	(envelope-from <bug-guix-bounces+larch=yhetil.org@gnu.org>)
	for <larch@yhetil.org>; Fri, 06 Dec 2024 19:51:37 +0100
X-Envelope-To: larch@yhetil.org
Authentication-Results: aspmx1.migadu.com;
	dkim=fail ("body hash did not verify") header.d=debbugs.gnu.org header.s=debbugs-gnu-org header.b=LoeZK6J5;
	dkim=fail ("body hash did not verify") header.d=gnu.org header.s=fencepost-gnu-org header.b=lqBJn2G3;
	dmarc=pass (policy=none) header.from=gnu.org;
	spf=pass (aspmx1.migadu.com: domain of "bug-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="bug-guix-bounces+larch=yhetil.org@gnu.org"
ARC-Seal: i=1; s=key1; d=yhetil.org; t=1733511096; a=rsa-sha256; cv=none;
	b=KGz05FdLk4GI8glefQOQg057WqnfAAtaBbfW/YAlnHFbBVmGXmNaapIqLkCwCB10uih6AH
	/U6VErEI1O9P2d69ssi8oN4R44v+Qn4Iuo7kVQ/A0V7sD+fkxqrP4ugR57E3dEwRaAEpQO
	VTGGGlSQozn16jnx/yeCZ/c7Ig0vaDEpR5Z2rxNCQVrnR3vzebr6zbmi+rHsHzp/x18UCL
	ZE4PGWh5dEMJXgk+Vo3H/y/yGWB1JCHyEs5eDuufULefOl/q4+aXuoW2gJZ+YvKenvPZvX
	KZYxt9sIzznG76DmaXLZmVDJP6y0IDrYW6bcD374x1m1u1kQkSk12d+5NdkLnA==
ARC-Authentication-Results: i=1;
	aspmx1.migadu.com;
	dkim=fail ("body hash did not verify") header.d=debbugs.gnu.org header.s=debbugs-gnu-org header.b=LoeZK6J5;
	dkim=fail ("body hash did not verify") header.d=gnu.org header.s=fencepost-gnu-org header.b=lqBJn2G3;
	dmarc=pass (policy=none) header.from=gnu.org;
	spf=pass (aspmx1.migadu.com: domain of "bug-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="bug-guix-bounces+larch=yhetil.org@gnu.org"
ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org;
	s=key1; t=1733511096;
	h=from:from:sender:sender:reply-to:subject:subject:date:date:
	 message-id:message-id:to:to:cc:cc:mime-version:mime-version:
	 content-type:content-type:resent-cc:resent-from:resent-sender:
	 resent-message-id:in-reply-to:in-reply-to:references:references:
	 list-id:list-help:list-unsubscribe:list-subscribe:list-post:
	 dkim-signature; bh=EeCADjYEcEZb0oK62c/irz7sPzCTFzqdLdOa5JcO6pY=;
	b=ByJUNzGcQZfQjsFj7+PoMcths4e1YEAGXHgQYhlyZm4sfxsx9WFd2A2MBS1hEjAtu0M+jC
	MRtJMMwPUsnOkFNJjuO0k4CZlv/xsNOLqYJ4hf2N6/B7kageT1iJgxZgjOZIi9LQxAXw0e
	hVSrsYnvr2iXK3mlCzpJzLH4hHGunzRQgzN9vXQfZAfcC5vsKrrb7QBfs1/Smu6pgR/xKC
	CCmdLJCHSPRPreyG3IyHjspnxdHx2X1eEH2gP/tJrhH69m6NwFd6T9b4yxiaV3ZXehZc1A
	EZg/vNnEJWcp1XqHQuSxu/Q91QotECQIhNWdDkm9hUC7v7C8meiTuMW33uTlAA==
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 73F1778D28
	for <larch@yhetil.org>; Fri, 06 Dec 2024 19:51:36 +0100 (CET)
Received: from localhost ([::1] helo=lists1p.gnu.org)
	by lists.gnu.org with esmtp (Exim 4.90_1)
	(envelope-from <bug-guix-bounces@gnu.org>)
	id 1tJdQB-0002GR-4y; Fri, 06 Dec 2024 13:51:24 -0500
Received: from eggs.gnu.org ([2001:470:142:3::10])
 by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <Debian-debbugs@debbugs.gnu.org>)
 id 1tJdPr-00028y-Lt
 for bug-guix@gnu.org; Fri, 06 Dec 2024 13:51:03 -0500
Received: from debbugs.gnu.org ([2001:470:142:5::43])
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128)
 (Exim 4.90_1) (envelope-from <Debian-debbugs@debbugs.gnu.org>)
 id 1tJdPr-0005Fn-7G
 for bug-guix@gnu.org; Fri, 06 Dec 2024 13:51:03 -0500
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed;
 d=debbugs.gnu.org; s=debbugs-gnu-org; 
 h=MIME-Version:Date:References:In-Reply-To:From:To:Subject;
 bh=eN0v8dmK5eyA6AI7FkLqrVyc9C/AUr2VkqGDeCWvNUs=; 
 b=LoeZK6J5swbqyH5spJB4HbIil+DHl/QO7Beqhl5R8e5OnoQ05I8a//+HBwS6vcztPv1Cgm447cDpjeE8yDcBX7ILFxaz6dbNDqKuPz8saJDZ4+MkmJsso9NTua7WKduBqtPBJ7g/eownqtKgtdUKWAwk6l6gN5LUAJ3etrJ5XOrm1a/t88J+IR5uWTv3G/+b1+Q2U0A4vR6hdTRHjEgOmQMR893IbOKJxC/Cc5GCktGGmE+dhHXjpGPffR5otdJ43i0mR0A2C4I34q/X/PxxrvoTpO/PIfpjeNHWwW8PTRFHI4yCop8ymdEuumFLTMBbw922E25YO5QQw8uMj/UF1A==;
Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2)
 (envelope-from <Debian-debbugs@debbugs.gnu.org>) id 1tJdPq-0000DD-1N
 for bug-guix@gnu.org; Fri, 06 Dec 2024 13:51:02 -0500
X-Loop: help-debbugs@gnu.org
Subject: bug#73181: guix-daemon fails when invoking =?UTF-8?Q?=E2=80=98guix_?=
 =?UTF-8?Q?authenticate=E2=80=99?= on the Hurd
Resent-From: Janneke Nieuwenhuizen <janneke@gnu.org>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces@debbugs.gnu.org>
Resent-CC: bug-guix@gnu.org
Resent-Date: Fri, 06 Dec 2024 18:51:01 +0000
Resent-Message-ID: <handler.73181.B73181.1733511010386@debbugs.gnu.org>
Resent-Sender: help-debbugs@gnu.org
X-GNU-PR-Message: followup 73181
X-GNU-PR-Package: guix
X-GNU-PR-Keywords: 
To: Ludovic =?UTF-8?Q?Court=C3=A8s?= <ludovic.courtes@inria.fr>
Cc: 73181@debbugs.gnu.org
Received: via spool by 73181-submit@debbugs.gnu.org id=B73181.1733511010386
 (code B ref 73181); Fri, 06 Dec 2024 18:51:01 +0000
Received: (at 73181) by debbugs.gnu.org; 6 Dec 2024 18:50:10 +0000
Received: from localhost ([127.0.0.1]:44277 helo=debbugs.gnu.org)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <debbugs-submit-bounces@debbugs.gnu.org>)
 id 1tJdOz-000067-I4
 for submit@debbugs.gnu.org; Fri, 06 Dec 2024 13:50:10 -0500
Received: from eggs.gnu.org ([209.51.188.92]:44754)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <janneke@gnu.org>) id 1tJdOw-00005K-Hu
 for 73181@debbugs.gnu.org; Fri, 06 Dec 2024 13:50:07 -0500
Received: from fencepost.gnu.org ([2001:470:142:3::e])
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <janneke@gnu.org>)
 id 1tJdOp-0004yP-GQ; Fri, 06 Dec 2024 13:49:59 -0500
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=MIME-Version:Date:References:In-Reply-To:Subject:To:
 From; bh=eN0v8dmK5eyA6AI7FkLqrVyc9C/AUr2VkqGDeCWvNUs=; b=lqBJn2G337RFy34y//YU
 Zi5+mz6tn+B38SUP4bvOVCAFK//G+eJ0sck4xazYzQXzGmk7Rbqw+Fdvjs2/CyQ2hfskAdtSQI4Af
 Nn4uUEmZrkLKmmJ5ifl2dpNGzCP13Txl2rgBh/s6ZSHX6K2L6hkUYLGqDl6kpX486OClmdvesbJ4P
 kvnfr1H8bK18SC3+MCcqtxj8dsZPnLdaLPe2z3eM9wJcEyPBo3SaQdyNMac3mycqPIZoVTwpUJVz9
 vWjhp5Ue0Ef8c43tKUARoFPpgNbb9xKTPadQiJVM3YiY1TfoQuFQ8tXnwiCCiFfl9aXRJ00JbSehd
 1LCyB1hRL0Zgng==;
From: Janneke Nieuwenhuizen <janneke@gnu.org>
In-Reply-To: <877c9hzsjy.fsf@inria.fr> ("Ludovic =?UTF-8?Q?Court=C3=A8s?="'s
 message of "Tue, 05 Nov 2024 15:03:29 +0100")
Organization: AvatarAcademy.nl
References: <87o74u5hcy.fsf@inria.fr> <87a5ge5d94.fsf@gnu.org>
 <87h68snkzk.fsf@gnu.org> <874j4n5s02.fsf@inria.fr>
 <87ed3phqfm.fsf@gnu.org> <877c9hzsjy.fsf@inria.fr>
X-Url: http://AvatarAcademy.nl
Date: Fri, 06 Dec 2024 19:49:52 +0100
Message-ID: <878qssbq9b.fsf@gnu.org>
User-Agent: Gnus/5.13 (Gnus v5.13)
MIME-Version: 1.0
Content-Type: multipart/mixed; boundary="=-=-="
X-BeenThere: debbugs-submit@debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
X-BeenThere: bug-guix@gnu.org
List-Id: Bug reports for GNU Guix <bug-guix.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-guix>,
 <mailto:bug-guix-request@gnu.org?subject=unsubscribe>
List-Archive: <https://lists.gnu.org/archive/html/bug-guix>
List-Post: <mailto:bug-guix@gnu.org>
List-Help: <mailto:bug-guix-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-guix>,
 <mailto:bug-guix-request@gnu.org?subject=subscribe>
Errors-To: bug-guix-bounces+larch=yhetil.org@gnu.org
Sender: bug-guix-bounces+larch=yhetil.org@gnu.org
X-Migadu-Flow: FLOW_IN
X-Migadu-Country: US
X-Migadu-Queue-Id: 73F1778D28
X-Migadu-Scanner: mx13.migadu.com
X-Migadu-Spam-Score: -4.04
X-Spam-Score: -4.04
X-TUID: glT8E+BDTXhX

--=-=-=
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable

Ludovic Court=C3=A8s writes:

Hello!

> <janneke@gnu.org> skribis:
>
>> Anyway, using this patch 0001 it seems that suppressing the warnings
>> works, I no longer get
>>
>> "GC Warning: Repeated allocation of very large block (appr. size 112
>> KiB):\n\tMay lead to memory leak and poor performance\n"
>>
>>
>> but still get
>>
>> unexpected build daemon error: stoi
>
> Damnit.  Could you check with rpctrace what the daemon receives?
>
> I wonder if I misunderstood what the root cause is.

TL;DR: Found it, attached is a patch to fix it.

Today I spent some time looking into this again, instrumented both
daemons with the attached patch for local-store.cc; a "guix copy
root@childhurd hello" gives:

host:
--8<---------------cut here---------------start------------->8---
accepted connection from pid 21474, user janneke
00 nondigit: ` ' [32]
01 read until now: >>>0<<<
00 nondigit: `:' [58]
01 read until now: >>>430<<<
--8<---------------cut here---------------end--------------->8---

childhurd:
--8<---------------cut here---------------start------------->8---
5 operations
00 nondigit: `G' [71]
01 read until now: >>><<<
02 nondigit: `G' [71]
03 nondigit: >>>GC Warning: Repeated allocation of very large block (appr. =
size 112 KiB):<<<
0 operations
--8<---------------cut here---------------end--------------->8---

...you already knew that from the rpctrace log.

So, the problem is that our patch doesrn't disable the warnings after all.
The guile-launcher has

guile-launcher.c:
--8<---------------cut here---------------start------------->8---
#if defined __GNU__
  /* XXX: On 32-bit GNU/Hurd (i586-gnu), libgc emits "Repeated allocation"
     warnings that are annoying and interfere with communications between
     'guix-daemon' and 'guix authenticate':
     <https://issues.guix.gnu.org/73181>.  Silence them.  */
  std::cerr << "silencing libgc warnings" << std::endl;
  GC_set_warn_proc (no_warnings);
#endif
  ..
  scm_boot_guile (argc, argv, inner_main, 0);
--8<---------------cut here---------------end--------------->8---

and then guile's gc.c just undoes that

init.c:
--8<---------------cut here---------------start------------->8---
scm_i_init_guile (void *base)
{
  ..
  scm_init_gc ();		/* Requires hooks and `get_internal_run_time' */
--8<---------------cut here---------------end--------------->8---

gc.c:
--8<---------------cut here---------------start------------->8---
void
scm_init_gc ()
{
  ..
  GC_set_warn_proc (scm_gc_warn_proc);
--8<---------------cut here---------------end--------------->8---

Doh' So, attached is also a patch for Guix (that I made for Guile) that
fixed offloading again for me.  Weirdly, I had to use
(overload-threshold #f) because my childhurd never falls below 1.0:

--8<---------------cut here---------------start------------->8---
root@guixygnu ~# uptime
 7:45:28 PM  up 35 minutes,  0 users,  load averages: 1.00, 1.01, 1.00
--8<---------------cut here---------------end--------------->8---


--8<---------------cut here---------------start------------->8---
19:25:48 janneke@glimdal:~/src/guix/hurd-team
$ ./pre-inst-env guix build --system=3Di586-gnu -e '(@@ (gnu packages comme=
ncement) gnu-make-boot0)' --with-configure-flag=3Dmake-boot0=3Dfoo=3Dbar
The following derivation will be built:
  /gnu/store/cp1fy0ig5p8d72vnz1vybw2cilii5g88-make-boot0-4.4.1.drv
process 4454 acquired build slot '/var/guix/offload/localhost:11022/0'
normalized load on machine 'localhost' is 1.00
building /gnu/store/cp1fy0ig5p8d72vnz1vybw2cilii5g88-make-boot0-4.4.1.drv...
guix offload: sending 41 store items (259 MiB) to 'localhost'...
[..]
@ build-started /gnu/store/cp1fy0ig5p8d72vnz1vybw2cilii5g88-make-boot0-4.4.=
1.drv - i586-gnu /var/log/guix/drvs/cp//1fy0ig5p8d72vnz1vybw2cilii5g88-make=
-boot0-4.4.1.drv.gz 360
[..]
@ build-succeeded /gnu/store/cp1fy0ig5p8d72vnz1vybw2cilii5g88-make-boot0-4.=
4.1.drv -
retrieving 1 store item from 'localhost'...
importing file or directory '/gnu/store/j83d3mzcjw83lcbvyd8hrs6i6ymdqbmc-ma=
ke-boot0-4.4.1'...
found valid signature for '/gnu/store/j83d3mzcjw83lcbvyd8hrs6i6ymdqbmc-make=
-boot0-4.4.1'
registering 1 items
done with offloaded '/gnu/store/cp1fy0ig5p8d72vnz1vybw2cilii5g88-make-boot0=
-4.4.1.drv'
successfully built /gnu/store/cp1fy0ig5p8d72vnz1vybw2cilii5g88-make-boot0-4=
.4.1.drv
/gnu/store/j83d3mzcjw83lcbvyd8hrs6i6ymdqbmc-make-boot0-4.4.1
--8<---------------cut here---------------end--------------->8---

WDYT?

Greetings,
Janneke


--=-=-=
Content-Type: text/x-patch
Content-Disposition: inline;
 filename=0001-REMOVEME-stoi-add-some-debugging.patch

>From 9695d17df1538460aad11500f56071500d9e4c80 Mon Sep 17 00:00:00 2001
Message-ID: <9695d17df1538460aad11500f56071500d9e4c80.1733510219.git.janneke@gnu.org>
From: Janneke Nieuwenhuizen <janneke@gnu.org>
Date: Mon, 18 Nov 2024 00:16:56 +0100
Subject: [PATCH] REMOVEME: stoi: add some debugging.

Change-Id: I114025c43cd2404a00dc65af7def06a312a31ca3
---
 nix/libstore/local-store.cc | 13 +++++++++++--
 1 file changed, 11 insertions(+), 2 deletions(-)

diff --git a/nix/libstore/local-store.cc b/nix/libstore/local-store.cc
index 0883a4bbce..e98bf04392 100644
--- a/nix/libstore/local-store.cc
+++ b/nix/libstore/local-store.cc
@@ -1164,9 +1164,9 @@ static std::shared_ptr<Agent> authenticationAgent()
 static int readInteger(int fd)
 {
     string str;
+    char ch;
 
     while (1) {
-        char ch;
         ssize_t rd = read(fd, &ch, 1);
         if (rd == -1) {
             if (errno != EINTR)
@@ -1177,11 +1177,20 @@ static int readInteger(int fd)
 	    if (isdigit(ch)) {
 		str += ch;
 	    } else {
-		break;
+              std::cerr << "00 nondigit: `" << ch << "' [" << (int) ch << "]" << std::endl;
+              std::cerr << "01 read until now: >>>" << str << "<<<" << std::endl;
+              break;
 	    }
         }
     }
 
+    if (str.empty()) {
+      std::cerr << "02 nondigit: `" << ch << "' [" << (int) ch << "]" << std::endl;
+      str += ch;
+      str += readLine(fd);
+      std::cerr << "03 nondigit: >>>" << str << "<<<" << std::endl;
+      throw EndOfFile("unexpected non-digit reading an integer");
+    }
     return stoi(str);
 }
 

base-commit: 889c396cc5fd948d2c874c2d4a51115f82591964
-- 
2.46.0


--=-=-=
Content-Type: text/x-patch; charset=utf-8
Content-Disposition: inline;
 filename=0001-gnu-guile-3.0-Silence-GC-warnings-on-the-Hurd.patch
Content-Transfer-Encoding: quoted-printable

>From c555134310728360cb3b12472e8d487421d57a7d Mon Sep 17 00:00:00 2001
Message-ID: <c555134310728360cb3b12472e8d487421d57a7d.1733509997.git.jannek=
e@gnu.org>
From: Janneke Nieuwenhuizen <janneke@gnu.org>
Date: Fri, 6 Dec 2024 16:25:54 +0100
Subject: [PATCH] gnu: guile-3.0: Silence GC warnings on the Hurd.

* gnu/packages/patches/guile-hurd-silence-gc-warnings.patch: New file.
* gnu/local.mk (dist_patch_DATA): Register it.
* gnu/packages/guile.scm (guile-3.0): When building for the Hurd, use it in
new stage "patch-silence-gc-warnings".

Change-Id: I48f2641a162c3fab15655293e10c4aa2200d5843
---
 gnu/local.mk                                  |  1 +
 gnu/packages/guile.scm                        | 11 ++++
 .../guile-hurd-silence-gc-warnings.patch      | 58 +++++++++++++++++++
 3 files changed, 70 insertions(+)
 create mode 100644 gnu/packages/patches/guile-hurd-silence-gc-warnings.pat=
ch

diff --git a/gnu/local.mk b/gnu/local.mk
index a7bd32453b..d848ceddc4 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -1520,6 +1520,7 @@ dist_patch_DATA =3D						\
   %D%/packages/patches/guile-fix-invalid-unicode-handling.patch \
   %D%/packages/patches/guile-gdbm-ffi-support-gdbm-1.14.patch	\
   %D%/packages/patches/guile-hurd-posix-spawn.patch		\
+  %D%/packages/patches/guile-hurd-silence-gc-warnings.patch	\
   %D%/packages/patches/guile-lzlib-hurd64.patch			\
   %D%/packages/patches/guile-present-coding.patch		\
   %D%/packages/patches/guile-rsvg-pkgconfig.patch		\
diff --git a/gnu/packages/guile.scm b/gnu/packages/guile.scm
index 69dff9211f..41fbd895ed 100644
--- a/gnu/packages/guile.scm
+++ b/gnu/packages/guile.scm
@@ -413,6 +413,17 @@ (define-public guile-3.0
                                (search-patch "guile-hurd-posix-spawn.patch=
")))
                           (invoke "patch" "--force" "-p1" "-i" patch))))
                    #~())
+            #$@(if (target-hurd?)
+                   #~((add-before 'build 'patch-silence-gc-warnings
+                        (lambda _
+                          ;; TODO: Move patch to 'source' on next rebuild
+                          ;; cycle.
+                          (define patch
+                            #$(local-file
+                               (search-patch
+                                "guile-hurd-silence-gc-warnings.patch")))
+                          (invoke "patch" "--force" "-p1" "-i" patch))))
+                   #~())
             #$@(if (system-hurd?)
                    #~((add-after 'unpack 'disable-popen.test-no-duplicate
                         ;; This test hangs on the Hurd.
diff --git a/gnu/packages/patches/guile-hurd-silence-gc-warnings.patch b/gn=
u/packages/patches/guile-hurd-silence-gc-warnings.patch
new file mode 100644
index 0000000000..a006d93361
--- /dev/null
+++ b/gnu/packages/patches/guile-hurd-silence-gc-warnings.patch
@@ -0,0 +1,58 @@
+From 1256fb0925c5ff7c94249f53e0fb47d1ec280b3f Mon Sep 17 00:00:00 2001
+From: Janneke Nieuwenhuizen <janneke@gnu.org>
+Date: Fri, 6 Dec 2024 16:18:13 +0100
+Subject: [PATCH] Silence GC warnings on the Hurd.
+MIME-Version: 1.0
+Content-Type: text/plain; charset=3DUTF-8
+Content-Transfer-Encoding: 8bit
+
+On 32-bit GNU/Hurd (i586-gnu), libgc emits "Repeated allocation"
+warnings that are annoying and interfere with communications between
+'guix-daemon' and 'guix authenticate':
+<https://issues.guix.gnu.org/73181>.
+
+* libguile/gc.c (scm_gc_no_warnings)[__GNU__]: New procedure.
+(scm_init_gc)[__GNU__]: Use it to silence GC warnings.
+
+Co-authored-by: Ludovic Court=C3=A8s <ludo@gnu.org>
+---
+ libguile/gc.c | 15 +++++++++++++++
+ 1 file changed, 15 insertions(+)
+
+diff --git a/libguile/gc.c b/libguile/gc.c
+index 3cbe43ec5..1ea4abcf8 100644
+--- a/libguile/gc.c
++++ b/libguile/gc.c
+@@ -84,6 +84,13 @@ int scm_debug_cells_gc_interval =3D 0;
+    garbage collection.  */
+ static SCM scm_protects;
+=20
++#if defined __GNU__
++#include <gc.h>
++static void
++scm_gc_no_warnings (char *message, GC_word arg)
++{
++}
++#endif
+=20
+ 
+=20
+@@ -616,7 +623,15 @@ scm_init_gc ()
+   scm_c_hook_add (&scm_after_gc_c_hook, accumulate_gc_timer, NULL, 0);
+=20
+   GC_set_oom_fn (scm_oom_fn);
++#if __GNU__
++  /* XXX: On 32-bit GNU/Hurd (i586-gnu), libgc emits "Repeated allocation"
++     warnings that are annoying and interfere with communications between
++     'guix-daemon' and 'guix authenticate':
++     <https://issues.guix.gnu.org/73181>.  Silence them.  */
++  GC_set_warn_proc (scm_gc_no_warnings);
++#else
+   GC_set_warn_proc (scm_gc_warn_proc);
++#endif
+   GC_set_start_callback (run_before_gc_c_hook);
+=20
+ #include "gc.x"
+--=20
+2.46.0
+

base-commit: 84fa76db424df8962ee21315ffd680c083edbf00
--=20
2.46.0


--=-=-=
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable


--=20
Janneke Nieuwenhuizen <janneke@gnu.org>  | GNU LilyPond https://LilyPond.org
Freelance IT https://www.JoyOfSource.com | Avatar=C2=AE https://AvatarAcade=
my.com

--=-=-=--