From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: MPS: weak hash tables Date: Tue, 02 Jul 2024 18:35:23 +0300 Message-ID: <86plrvbydg.fsf@gnu.org> References: <86ed8cc4un.fsf@gnu.org> <86zfqzc3ky.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="36008"; mail-complaints-to="usenet@ciao.gmane.io" Cc: gerd.moellmann@gmail.com, eller.helmut@gmail.com, emacs-devel@gnu.org To: Pip Cet Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Tue Jul 02 17:36:25 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 1sOfYP-00097B-4s for ged-emacs-devel@m.gmane-mx.org; Tue, 02 Jul 2024 17:36:25 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sOfXZ-0000dC-1g; Tue, 02 Jul 2024 11:35:33 -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 1sOfXW-0000cp-Pv for emacs-devel@gnu.org; Tue, 02 Jul 2024 11:35:30 -0400 Original-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 1sOfXW-0006OV-H0; Tue, 02 Jul 2024 11:35:30 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=vdw4Qu0XoTg4w6gxDSIWPXFQDpKtjBYZMObBc/iaSAg=; b=nkYbhROT4ovaY4Pwmy9k RMaQ/ReEVEVZrfRhujPEPZyg0FNUUOwY3yyoCgBmmJZZ5/+TpG2xDG1GqE5M9Ne+B0tzyycGHtIkB 0mAvCmmQ3UVVKBtcArO2bRJZlCc03m9bbPBnoBhWrDwT2uLOVRfLDyrwGl9Zfu/G0ASFOen4pgzSo iU1FytrRj/WJyDFUSXB0IOyrFSxumgKuNalPdHEGSfHQlh26Dwc2JWBVYkq/Ocm+pOGO3RRo3ha0y 5cCAWwsVcf2tMusFa+RWlQL61vxPnb7PLV17YqPs96oRbzv54HhAF9jf6ZzMRBhQ7eEBq+r2zkNt7 T17iCMGDESWL0A==; In-Reply-To: (message from Pip Cet on Tue, 02 Jul 2024 15:03:44 +0000) 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:321176 Archived-At: > Date: Tue, 02 Jul 2024 15:03:44 +0000 > From: Pip Cet > Cc: Gerd Möllmann , eller.helmut@gmail.com, emacs-devel@gnu.org > > That means we must do one of the following: > > 1. mangle all Lisp_Objects to pointers or fixnums when storing them in a weak hash table, and unmangle them upon retrieval > 2. not use 32-bit x86 machines > 3. modify MPS > 4. throw caution to the wind and just hope it works I don't understand why (1) is needed. Lisp objects are already pointers in disguise, so what exactly is the problem here? I also don't understand how come an _optimization_ turned out to do us some harm.