From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Pip Cet Newsgroups: gmane.emacs.devel Subject: Re: MPS: weak hash tables Date: Mon, 01 Jul 2024 21:16:31 +0000 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="14386"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Eli Zaretskii , Helmut Eller , Emacs Devel To: =?utf-8?Q?Gerd_M=C3=B6llmann?= Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Tue Jul 02 04:23:51 2024 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1sOTBO-0003fD-LV for ged-emacs-devel@m.gmane-mx.org; Tue, 02 Jul 2024 04:23:50 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sOTAy-0002Ng-UB; Mon, 01 Jul 2024 22:23:24 -0400 Original-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 1sOOO9-00013u-7R for emacs-devel@gnu.org; Mon, 01 Jul 2024 17:16:41 -0400 Original-Received: from mail-40133.protonmail.ch ([185.70.40.133]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sOOO6-0008Hv-Gg for emacs-devel@gnu.org; Mon, 01 Jul 2024 17:16:40 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail3; t=1719868596; x=1720127796; bh=0QrDrEcK2EHCyY1cpG6LBY2jm8v2Xqyj/+yAiF22xC4=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: Feedback-ID:From:To:Cc:Date:Subject:Reply-To:Feedback-ID: Message-ID:BIMI-Selector; b=LjMxDbW0B700MLA9Gg+v0t/hfYOIUdMXjGydJOhDpEsVmfknE2snXHHEnG6d1ab07 ck/NDETfoRtNK2fNFbnOm9EeS0cThqlZCSuHxR7VeJpQyqvLZIwt1UnUWh1Him4QaN 87Mf4H8FSwFD81h0mPdO5Xb2rJBlMthsUx8BBTZH8pzL4Ch1fUs63fZ7Z+uiCZNFPW UurL9fUPa3JJull25IUqtGX7KcC7qHLWiYg55jb8gIWUCOqsb7pOlv3QmqZVZomqHE 0ZiUqgiXdQ0Y+nPPKJC3xPFOf1ZQ+R2SjMTeXcVB1Q2fCzgfrSK1n5HzJhqF/j5T4Q 9nzsGcuQ7hOhw== In-Reply-To: Feedback-ID: 112775352:user:proton X-Pm-Message-ID: 1538e3aa6609ca9c3f5f56e2e3ef7ffff8f5a735 Received-SPF: pass client-ip=185.70.40.133; envelope-from=pipcet@protonmail.com; helo=mail-40133.protonmail.ch X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Mailman-Approved-At: Mon, 01 Jul 2024 22:23:14 -0400 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:321080 Archived-At: On Monday, July 1st, 2024 at 20:47, Gerd M=C3=B6llmann wrote: > Hi Pip, >=20 > I've begun to read the new code a little bit now, and I don't understand > the index vector allocation yet. It's currently a gross overallocation. The index starts at ret->strong->ent= ries + 3 * size and ends at ret->strong->entries + 5 * size, giving us 2 * = size entries. Index bits is elogb (size) + 1, so the actual index length is= at most 2 * size for size > 1, as it is in our case because I force it to = be at least 65. > I see that the index_bits from compute_index_bits are passed to the > allocation functions in igc.c, but they don't seem to be used for > determining how much to allocate for the index. That is correct. > I think that the index is given 2 * table_size room ATM, but I'm not > sure if I read that right, and it's late. Is it sure that that suffices? I believe it is, but it needs fixing anyway. Will do that next. Thanks for the heads-up! Pip