From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: ludo@gnu.org (Ludovic =?UTF-8?Q?Court=C3=A8s?=) Newsgroups: gmane.lisp.guile.bugs Subject: bug#28590: Weak tables in 2.2.2 grow indefinitely Date: Mon, 02 Oct 2017 11:53:09 +0200 Message-ID: <8760bxri4a.fsf@gnu.org> References: <87poafkvsm.fsf@gnu.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Trace: blaine.gmane.org 1506938116 390 195.159.176.226 (2 Oct 2017 09:55:16 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Mon, 2 Oct 2017 09:55:16 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.3 (gnu/linux) Cc: Andy Wingo To: 28590@debbugs.gnu.org Original-X-From: bug-guile-bounces+guile-bugs=m.gmane.org@gnu.org Mon Oct 02 11:55:12 2017 Return-path: Envelope-to: guile-bugs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dyxRP-0007sy-7l for guile-bugs@m.gmane.org; Mon, 02 Oct 2017 11:55:11 +0200 Original-Received: from localhost ([::1]:51466 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dyxRV-0007Sr-1t for guile-bugs@m.gmane.org; Mon, 02 Oct 2017 05:55:17 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:59387) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dyxRK-0007NR-Mn for bug-guile@gnu.org; Mon, 02 Oct 2017 05:55:11 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dyxRG-0006GS-MM for bug-guile@gnu.org; Mon, 02 Oct 2017 05:55:06 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:34769) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dyxRG-0006GM-IU for bug-guile@gnu.org; Mon, 02 Oct 2017 05:55:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1dyxRG-0006wT-B9; Mon, 02 Oct 2017 05:55:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: ludo@gnu.org (Ludovic =?UTF-8?Q?Court=C3=A8s?=) Original-Sender: "Debbugs-submit" Resent-CC: bug-guile@gnu.org Resent-Date: Mon, 02 Oct 2017 09:55:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 28590 X-GNU-PR-Package: guile X-GNU-PR-Keywords: Original-Received: via spool by 28590-submit@debbugs.gnu.org id=B28590.150693804926617 (code B ref 28590); Mon, 02 Oct 2017 09:55:02 +0000 Original-Received: (at 28590) by debbugs.gnu.org; 2 Oct 2017 09:54:09 +0000 Original-Received: from localhost ([127.0.0.1]:43450 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dyxQP-0006vF-5T for submit@debbugs.gnu.org; Mon, 02 Oct 2017 05:54:09 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:40027) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dyxQN-0006ul-2F for 28590@debbugs.gnu.org; Mon, 02 Oct 2017 05:54:07 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dyxQD-0005f5-E2 for 28590@debbugs.gnu.org; Mon, 02 Oct 2017 05:54:01 -0400 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:35508) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dyxPU-0005P9-My; Mon, 02 Oct 2017 05:53:12 -0400 Original-Received: from [193.50.110.164] (port=41908 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1dyxPU-0005EE-4T; Mon, 02 Oct 2017 05:53:12 -0400 In-Reply-To: <87poafkvsm.fsf@gnu.org> ("Ludovic \=\?utf-8\?Q\?Court\=C3\=A8s\=22'\?\= \=\?utf-8\?Q\?s\?\= message of "Mon, 25 Sep 2017 10:49:13 +0200") X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-guile@gnu.org List-Id: "Bug reports for GUILE, GNU's Ubiquitous Extension Language" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guile-bounces+guile-bugs=m.gmane.org@gnu.org Original-Sender: "bug-guile" Xref: news.gmane.org gmane.lisp.guile.bugs:8840 Archived-At: ludo@gnu.org (Ludovic Court=C3=A8s) skribis: > On 2.2.2, the heap grows indefinitely (though logarithmically). It=E2=80= =99s > not deterministic though: sometimes the heap size stabilizes in the > 140=E2=80=93300=C2=A0MiB range, and sometimes it keeps growing endlessly = even though > the table size reaches a maxium at 7,190,537 entries. Below is a simple reproducer in C that I=E2=80=99ve also reported at : --8<---------------cut here---------------start------------->8--- #define GC_DEBUG 1 #include #include #include int main () { GC_INIT (); while (1) { unsigned int count =3D 777 * (random () % 1000); void **p =3D GC_MALLOC_ATOMIC (count * sizeof *p); for (unsigned int i =3D 0; i < count; i++) { void *key =3D GC_MALLOC_ATOMIC (10); p[i] =3D key; GC_GENERAL_REGISTER_DISAPPEARING_LINK (&p[i], key); /* <- !!! */ } static unsigned int loops =3D 0; if (loops++ % 10 =3D=3D 0) printf ("iteration %4u, heap size =3D %li MiB\n", loops, GC_get_heap_size () / (1024 * 1024)); } } --8<---------------cut here---------------end--------------->8--- Ludo=E2=80=99.