From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id KOPwJuXvVWMWdgEAbAwnHQ (envelope-from ) for ; Mon, 24 Oct 2022 03:52:37 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id SPDmJuXvVWPf/QAAauVa8A (envelope-from ) for ; Mon, 24 Oct 2022 03:52:37 +0200 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 54D7832EDB for ; Mon, 24 Oct 2022 03:52:37 +0200 (CEST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1omjTw-0003UY-G1 for larch@yhetil.org; Sun, 23 Oct 2022 18:30:12 -0400 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 ) id 1omL0M-0004Um-EA for bug-guix@gnu.org; Sat, 22 Oct 2022 16:22:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1omL0M-0007qf-6o for bug-guix@gnu.org; Sat, 22 Oct 2022 16:22:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1omL0M-00059c-1z for bug-guix@gnu.org; Sat, 22 Oct 2022 16:22:02 -0400 X-Loop: help-debbugs@gnu.org Subject: bug#58631: [Shepherd] Indefinite heap growth (memory leak) Resent-From: Ludovic =?UTF-8?Q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Sat, 22 Oct 2022 20:22:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 58631 X-GNU-PR-Package: guix X-GNU-PR-Keywords: To: Liliana Marie Prikler Cc: 58631@debbugs.gnu.org Received: via spool by 58631-submit@debbugs.gnu.org id=B58631.166647009519774 (code B ref 58631); Sat, 22 Oct 2022 20:22:02 +0000 Received: (at 58631) by debbugs.gnu.org; 22 Oct 2022 20:21:35 +0000 Received: from localhost ([127.0.0.1]:42438 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1omKzu-00058r-I3 for submit@debbugs.gnu.org; Sat, 22 Oct 2022 16:21:34 -0400 Received: from eggs.gnu.org ([209.51.188.92]:48438) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1omKzm-00058L-4o for 58631@debbugs.gnu.org; Sat, 22 Oct 2022 16:21:29 -0400 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 ) id 1omKzf-0007iR-Cr; Sat, 22 Oct 2022 16:21:19 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:In-Reply-To:Date:References:Subject:To: From; bh=B1rZif7uPQTTXckiQIBYg4sCjlUa1KbFl5ZhUWJOxIg=; b=olsDwSqUeIq7oTCuo/cG lz7CaedRALBfoJzJq8wp7bjM3lGVP4CaGRcyqB9ZCCLGJE8RTcBJG2JJW+xDAtXVZsNuGlmRRPzMB aWSU4ApsvLJy6nm2fIYr2bUcb/G3ie6uaxAMFfcqO4iUInAxRK9gjIODEu1IKQXD20gRttxv5bc9Y 9JGLHM21w6H/HChsNDw9lKP9qZN1vGYRrMoTEv7T1JiG7c3+lDXS4NrnMrMUO096pNuk719rIsjLZ D+uIQOkCxR84Y+MmSRE5ZpdgWo4z+ov+Q+B8uB0hJFvNs/xklATH9R4ac9ilJ/oV9+MuMHRo55Bir uwkNTy3t39szeQ==; Received: from 91-160-117-201.subs.proxad.net ([91.160.117.201] helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1omKyz-0004Dk-Ew; Sat, 22 Oct 2022 16:20:47 -0400 From: Ludovic =?UTF-8?Q?Court=C3=A8s?= References: <87pmeohute.fsf@gnu.org> <87sfjjhjcd.fsf@gnu.org> <87a65qhmh3.fsf@gnu.org> <3ba120cf2d9ec36d15bc89bc797eb004dbe91c18.camel@ist.tugraz.at> Date: Sat, 22 Oct 2022 22:20:35 +0200 In-Reply-To: <3ba120cf2d9ec36d15bc89bc797eb004dbe91c18.camel@ist.tugraz.at> (Liliana Marie Prikler's message of "Fri, 21 Oct 2022 15:07:11 +0200") Message-ID: <87tu3v4nl8.fsf_-_@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable 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 List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guix-bounces+larch=yhetil.org@gnu.org Sender: "bug-Guix" X-Migadu-Flow: FLOW_IN X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1666576357; 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: content-transfer-encoding:content-transfer-encoding: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=B1rZif7uPQTTXckiQIBYg4sCjlUa1KbFl5ZhUWJOxIg=; b=TXJZb49M+0dteGAihYJkYpVnnZroLqpQcLriB/tNaYyFhV5Ng5sDG2xU4dOoZILfQkMA29 oShNkVo9pfTuZyDw5jlPRLD7zO9Tn424PR4/4eUCcdF8I2LESIZ50ut0r5DA+pf+hv26S5 AJqLuk8WDswhv2eW4Xzv6ro4MDCM7aX2W6Fz+J4N9BoICJiSU0lRcHMR5cilwXwkJdsYH2 zoKVZ+Lia22EeJ+1R+Ofzb1ZjmhWODoV/qdJxKejduvXawCOcTmyXZwIjegR9i3cAi0qMG VVVp5sU6t0uDst6p3byK7xtgnQHE2KNXK6q3VNH+6rM8jbZTZq3bjJK3BK3iqQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1666576357; a=rsa-sha256; cv=none; b=mSvYhg2QR3fBnpadAiQs6CMHuxKqsQ0qVQjdNE9sQpXhlorPGrNZYSHESg+E3wuXzVbO5Y tB7PEjb25v9TKpRZC1DlJvRKmu2dUYTRhJ3RyD4R8wHARrmuwLq3vpZ5s845FvlHl4qIic p0UrQkILMxjPMGMtBMhHun6LDc/1HtRe9/n1etN8rulsFLgVwjOWNEcPXxEG8OkmAJwMQ/ BBYuCylklmNNI/Uk0vSrDm0CdIzoLkzB73UL3OoMI6wdIGid9WQr7QKWMjJHEdul765kto nIwghjowPABBAUCJ04lY1sOldgNqURuYwwqZhsAanaplvRs4ZlZw1UlPhv9JUA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gnu.org header.s=fencepost-gnu-org header.b=olsDwSqU; 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" X-Migadu-Spam-Score: -1.91 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gnu.org header.s=fencepost-gnu-org header.b=olsDwSqU; 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" X-Migadu-Queue-Id: 54D7832EDB X-Spam-Score: -1.91 X-Migadu-Scanner: scn0.migadu.com X-TUID: ufttt/klVrlE Liliana Marie Prikler skribis: > Am Donnerstag, dem 20.10.2022 um 11:29 +0200 schrieb Ludovic Court=C3=A8s: >> Logging as performed by =E2=80=98%service-file-logger=E2=80=99 is quite = GC-intensive >> (but shouldn=E2=80=99t be leaky!); this bit: >>=20 >> =C2=A0=C2=A0=C2=A0=C2=A0 (let ((prefix (strftime default-logfile-date-fo= rmat >> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0 (localtime (current-time))))) >> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 (format output "~a~a~%" prefix line) >> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 (loop)) > > (let ((prefix (strftime default-logfile-date-format > (localtime (current-time))))) > (format output "~a~a~%" prefix line) > (loop)) > > Would it make a difference if you instead wrote > > (let ((prefix (strftime default-logfile-date-format > (localtime (current-time))))) > (format output "~a~a~%" prefix line)) > (loop) > > ? Semantically, they're equivalent (perhaps with a wrapping begin > needed), but the compiler might fail to see this. I=E2=80=99m confident the compiler does the right thing, and it=E2=80=99s a= tail call so =E2=80=98prefix=E2=80=99 doesn=E2=80=99t outlive one loop iteration. Ludo=E2=80=99.