From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: GC crashes Date: 07 Dec 2003 21:52:11 -0500 Sender: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Message-ID: References: <20031124.110938.193696628.wl@gnu.org> <200311260203.LAA26808@etlken.m17n.org> <20031128.103107.41640217.wl@gnu.org> <200312011240.VAA05762@etlken.m17n.org> <200312022337.IAA02026@etlken.m17n.org> <200312032319.IAA04473@etlken.m17n.org> <200312040112.KAA04711@etlken.m17n.org> <200312040221.LAA04807@etlken.m17n.org> <200312080231.LAA12773@etlken.m17n.org> NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1070852096 7911 80.91.224.253 (8 Dec 2003 02:54:56 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Mon, 8 Dec 2003 02:54:56 +0000 (UTC) Cc: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Mon Dec 08 03:54:53 2003 Return-path: Original-Received: from quimby.gnus.org ([80.91.224.244]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1ATBXx-0000JL-00 for ; Mon, 08 Dec 2003 03:54:53 +0100 Original-Received: from monty-python.gnu.org ([199.232.76.173]) by quimby.gnus.org with esmtp (Exim 3.35 #1 (Debian)) id 1ATBXw-00077V-00 for ; Mon, 08 Dec 2003 03:54:52 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.24) id 1ATCTq-00075P-Kw for emacs-devel@quimby.gnus.org; Sun, 07 Dec 2003 22:54:42 -0500 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.24) id 1ATCTO-00071R-Ix for emacs-devel@gnu.org; Sun, 07 Dec 2003 22:54:14 -0500 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.24) id 1ATCSs-0006jn-BT for emacs-devel@gnu.org; Sun, 07 Dec 2003 22:54:13 -0500 Original-Received: from [132.204.24.67] (helo=mercure.iro.umontreal.ca) by monty-python.gnu.org with esmtp (Exim 4.24) id 1ATCSs-0006jj-1o for emacs-devel@gnu.org; Sun, 07 Dec 2003 22:53:42 -0500 Original-Received: from vor.iro.umontreal.ca (vor.iro.umontreal.ca [132.204.24.42]) by mercure.iro.umontreal.ca (Postfix) with ESMTP id 69CFD20F6C; Sun, 7 Dec 2003 21:52:12 -0500 (EST) Original-Received: by vor.iro.umontreal.ca (Postfix, from userid 20848) id E05563CFD9; Sun, 7 Dec 2003 21:52:11 -0500 (EST) Original-To: Kenichi Handa In-Reply-To: <200312080231.LAA12773@etlken.m17n.org> Original-Lines: 34 User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50 X-DIRO-MailScanner-Information: Please contact the ISP for more information X-DIRO-MailScanner: Found to be clean X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.2 Precedence: list List-Id: Emacs development discussions. List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Xref: main.gmane.org gmane.emacs.devel:18532 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:18532 >> No, it just means we have to change init_fns. > Then, it seems that moving this: > Vweak_hash_tables = Qnil; > to syms_of_fns is the easiest solution. Sounds right. And we should rename it as well because it's not a lisp variable so it shouldn't start with `V'. >> No, it shouldn't. [ Side note: whether an integer should >> be considered as "always live" or as "always GC-able" from >> the point of view of weakness is not obvious. ] > Ah! I blindly believed that an integer is always GC-able, > but survives_gc_p (obj) returns 1 if obj is an integer. So > if we make a composition hash table with :weak t, an element > of the table always survives GC, thus is never removed. It That's right. > doesn't fit my intuition but, I'd like to avoid discussing > on it for the momemnt. There's nothing useful to discuss indeed. It's just interesting that it's a case where the nice theory of "remove if GC-able" needs to be adjusted for a particular case. We could also decide that int does not survive_gc_p, but it would be less useful. > I'll try :weak `key' and check if it really works locally. > It seems that we can't commit anything for a while anyway. It shouldn't make any difference in practice. Stefan