From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Stefan Monnier via "Bug reports for GNU Emacs, the Swiss army knife of text editors" Newsgroups: gmane.emacs.bugs Subject: bug#68244: hash-table improvements Date: Thu, 08 Feb 2024 09:19:43 -0500 Message-ID: References: <170438379722.3921.9312235725296561206@vcs2.savannah.gnu.org> <20240104155642.B4A99C00344@vcs2.savannah.gnu.org> <8d49ebdc-9da7-4e70-a080-d8e892b980b6@gutov.dev> <08314177-5AE9-4352-94A0-641830B4094D@gmail.com> <19265EA5-E6F3-446C-AD9B-763693CF0A48@gmail.com> Reply-To: Stefan Monnier Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="32615"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: Gerd =?UTF-8?Q?M=C3=B6llmann?= , Dmitry Gutov , Eli Zaretskii , 68244@debbugs.gnu.org, Stefan Kangas To: Mattias =?UTF-8?Q?Engdeg=C3=A5rd?= Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Feb 08 15:21:12 2024 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1rY5H4-0008Hh-Lg for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 08 Feb 2024 15:21:10 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rY5Gt-00013h-I4; Thu, 08 Feb 2024 09:20:59 -0500 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 1rY5Gl-000138-Hf for bug-gnu-emacs@gnu.org; Thu, 08 Feb 2024 09:20:53 -0500 Original-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 ) id 1rY5Gi-0005gH-4s for bug-gnu-emacs@gnu.org; Thu, 08 Feb 2024 09:20:49 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rY5Gw-0000tf-Gj for bug-gnu-emacs@gnu.org; Thu, 08 Feb 2024 09:21:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Stefan Monnier Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 08 Feb 2024 14:21:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 68244 X-GNU-PR-Package: emacs Original-Received: via spool by 68244-submit@debbugs.gnu.org id=B68244.17074020163363 (code B ref 68244); Thu, 08 Feb 2024 14:21:02 +0000 Original-Received: (at 68244) by debbugs.gnu.org; 8 Feb 2024 14:20:16 +0000 Original-Received: from localhost ([127.0.0.1]:59392 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rY5GB-0000sB-Pe for submit@debbugs.gnu.org; Thu, 08 Feb 2024 09:20:16 -0500 Original-Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:46621) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rY5GA-0000rv-4t for 68244@debbugs.gnu.org; Thu, 08 Feb 2024 09:20:14 -0500 Original-Received: from pmg3.iro.umontreal.ca (localhost [127.0.0.1]) by pmg3.iro.umontreal.ca (Proxmox) with ESMTP id D0FA9441804; Thu, 8 Feb 2024 09:19:53 -0500 (EST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1707401992; bh=MXP7ndE/+uKAg3I4LUcTC66dn+1Ul2vJ+jNHjPKKliw=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=pkRoF4HMHM9UVRyQsWvxOIWGMPTzHwMi8Kwh+tckEXzM6MDbxY5zCxTsa78FBLnze eWrXJPh0CIS11/oc8HZvVyuY3NZCenjZTVBrodKyi0jEFJWCJFrT+OUvuhEje2VbbT HHx4256LE6hnCelYjtm74DQl6O9RR8RyAjGEP40ysyrvRGH3qN+rCxA7yk+QVu6hE0 /B12Xu3zapL1A5SVD7OOeu9lf9iNgSB2m0Qh/onWa0KuUTjTyxsWnXoiOm91L0EZ3Z zO1wzSkELCI20HkaqlOMikELoG3cT38sKL6Cm0/GU2xLOCjI/p0HtHSxLqfUckbztC ef5p+GWBdVybg== Original-Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg3.iro.umontreal.ca (Proxmox) with ESMTP id 696344411F3; Thu, 8 Feb 2024 09:19:52 -0500 (EST) Original-Received: from pastel (unknown [104.247.238.113]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id 2FDEF120483; Thu, 8 Feb 2024 09:19:52 -0500 (EST) In-Reply-To: ("Mattias =?UTF-8?Q?Engdeg=C3=A5rd?="'s message of "Thu, 8 Feb 2024 10:46:27 +0100") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:279636 Archived-At: > We should probably do the same for obarrays but those have more low-hanging > fruit. I'll be back with some changes. For me, the more important aspect of obarrays is that we should have a separate obarray type (if it can share code with hash-table, that's gravy). Of course, we'd still have to *also* accept plain vectors, sadly. Some years ago I proposed a patch which changed nothing to the implementation of obarrays but introduced a new PVEC_OBARRAY which was used instead of the "PVEC_VECTOR" (and given the variable size of vectors *and* of those obarrays, these two tags were treated specially). It suffered from the lack of bits in the word that holds the PVEC_* tag and the vector's size limiting the size of obarrays to too-small value. But I think we can do something much simpler: vectors are accepted by simply storing in the first field a reference to the actual obarray object, so there's no need to play any games and/or share representation between vectors and obarray. Stefan