From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Dmitry Antipov Newsgroups: gmane.emacs.devel Subject: Reachable killed buffers [Was: Re: [Emacs-diffs] /srv/bzr/emacs/trunk r109890: Do not mark objects from deleted buffers, windows and frames] Date: Mon, 10 Sep 2012 13:46:05 +0400 Message-ID: <504DB6DD.9030002@yandex.ru> References: <504848D0.4020908@yandex.ru> <5048D826.3040103@yandex.ru> <5049C400.8070400@gmx.at> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1347270383 25054 80.91.229.3 (10 Sep 2012 09:46:23 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 10 Sep 2012 09:46:23 +0000 (UTC) Cc: emacs-devel@gnu.org To: martin rudalics , Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Sep 10 11:46:25 2012 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1TB0ZU-0004bo-9s for ged-emacs-devel@m.gmane.org; Mon, 10 Sep 2012 11:46:24 +0200 Original-Received: from localhost ([::1]:44600 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TB0ZQ-0002Zp-VP for ged-emacs-devel@m.gmane.org; Mon, 10 Sep 2012 05:46:20 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:51053) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TB0ZJ-0002Zk-5F for emacs-devel@gnu.org; Mon, 10 Sep 2012 05:46:18 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TB0ZF-0007WX-5E for emacs-devel@gnu.org; Mon, 10 Sep 2012 05:46:13 -0400 Original-Received: from forward7.mail.yandex.net ([77.88.61.37]:34062) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TB0ZE-0007Rm-P1 for emacs-devel@gnu.org; Mon, 10 Sep 2012 05:46:09 -0400 Original-Received: from smtp6.mail.yandex.net (smtp6.mail.yandex.net [77.88.61.56]) by forward7.mail.yandex.net (Yandex) with ESMTP id 61A911C19EF; Mon, 10 Sep 2012 13:46:06 +0400 (MSK) Original-Received: from smtp6.mail.yandex.net (localhost [127.0.0.1]) by smtp6.mail.yandex.net (Yandex) with ESMTP id DE7A11640758; Mon, 10 Sep 2012 13:46:05 +0400 (MSK) Original-Received: from unknown (unknown [37.139.80.10]) by smtp6.mail.yandex.net (nwsmtp/Yandex) with ESMTP id k5OmiWjf-k5OCRJWv; Mon, 10 Sep 2012 13:46:05 +0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex.ru; s=mail; t=1347270365; bh=wy8tE46rdhA20cFBz08k69xwjzkT11ptHZyzcK6ybEA=; h=Message-ID:Date:From:User-Agent:MIME-Version:To:CC:Subject: References:In-Reply-To:Content-Type:Content-Transfer-Encoding; b=Y5KZYrkan2A4zdcywKyZuU0kiuxT7qOCTh16c1TLde1tTBnZShXa1xepBUT+Fh7HO zevsb8wooNi49QT4JvSECfL+EqsGBZUpsyX6CQtHMKsWdDvYnU/IePVXkhTjvWoT7y 6utRbbZHyH56oyZnXCLJpE6qXJct2Uc/+i7hMm5Y= User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:15.0) Gecko/20120824 Thunderbird/15.0 In-Reply-To: <5049C400.8070400@gmx.at> X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 77.88.61.37 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 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.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:153211 Archived-At: I found two places where the killed buffer may survive for a while and so create some unneeded pressure to GC: 1) 'where' slot of Lisp_Buffer_Local_Value, which has local_if_set 0. When the buffer is killed, swap_out_buffer_local_variables can't see this BLV's symbol because it's not in buffer's local_var_alist. Shouldn't we call to swap_in_global_binding for such an "orphaned" BLVs? 2) 'prev_buffers' and 'next_buffers' of struct window. When the buffer is killed, replace_buffer_in_windows should remove it from these lists; but window-list-1 returns only live windows, so we may end up with dead window with a long list of killed buffers referenced from prev_buffers and/or next_buffers. Dmitry