From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Jean Louis Newsgroups: gmane.emacs.bugs Subject: bug#43389: 28.0.50; Emacs memory leaks Date: Tue, 10 Nov 2020 22:51:16 +0300 Message-ID: References: <875z8fc224.fsf@web.de> <20200915175418.GV20869@maokai> <838sda98jm.fsf@gnu.org> <20200915211209.GW20869@maokai> <83pn6l7ozj.fsf@gnu.org> <20200917204704.GA20217@maokai> <83zh5n4hpd.fsf@gnu.org> <878sbagsx8.fsf@web.de> <83d00l2oz9.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="3019"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mutt/2.0 (3d08634) (2020-11-07) Cc: michael_heerdegen@web.de, 43389@debbugs.gnu.org, RLAdams@AdamsInfoServ.Com To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Nov 10 21:58:27 2020 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 1kcaih-0000dR-28 for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 10 Nov 2020 21:58:27 +0100 Original-Received: from localhost ([::1]:51960 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kcaif-00068D-Vc for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 10 Nov 2020 15:58:26 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:45128) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kcaiI-00067N-B4 for bug-gnu-emacs@gnu.org; Tue, 10 Nov 2020 15:58:03 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:55786) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kcaiH-00039i-VF for bug-gnu-emacs@gnu.org; Tue, 10 Nov 2020 15:58:01 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kcaiH-0005r1-RV for bug-gnu-emacs@gnu.org; Tue, 10 Nov 2020 15:58:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Jean Louis Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 10 Nov 2020 20:58:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 43389 X-GNU-PR-Package: emacs Original-Received: via spool by 43389-submit@debbugs.gnu.org id=B43389.160504183622426 (code B ref 43389); Tue, 10 Nov 2020 20:58:01 +0000 Original-Received: (at 43389) by debbugs.gnu.org; 10 Nov 2020 20:57:16 +0000 Original-Received: from localhost ([127.0.0.1]:39093 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kcahY-0005pd-4P for submit@debbugs.gnu.org; Tue, 10 Nov 2020 15:57:16 -0500 Original-Received: from static.rcdrun.com ([95.85.24.50]:50723) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kcahW-0005pU-4R for 43389@debbugs.gnu.org; Tue, 10 Nov 2020 15:57:15 -0500 Original-Received: from localhost ([::ffff:197.157.34.177]) (AUTH: PLAIN admin, TLS: TLS1.2,256bits,ECDHE_RSA_AES_256_GCM_SHA384) by static.rcdrun.com with ESMTPSA id 00000000002C0005.000000005FAAFEA8.00001985; Tue, 10 Nov 2020 20:57:12 +0000 Content-Disposition: inline In-Reply-To: <83d00l2oz9.fsf@gnu.org> 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" Xref: news.gmane.io gmane.emacs.bugs:193058 Archived-At: * Eli Zaretskii [2020-11-10 18:47]: > > Date: Tue, 10 Nov 2020 01:33:17 +0300 > > From: Jean Louis > > Cc: Eli Zaretskii , 43389@debbugs.gnu.org, > > Russell Adams > > > > It was happening regularly under EXWM. Memory get occupied more and > > more and more until it does not go any more, swapping becomes tedious > > and computer becomes non-responsive. Then I had to kill it. By using > > symon-mode I could see swapping of 8 GB and more. My memory is 4 GB > > plus 8 GB swap currently. > > > > This similar condition takes place only after keeping Emacs long in > > memory like maybe 5-8 hours. > > > > After putting laptop to sleep it happens more often. > > > > When I changed to IceWM this happened only once. > > If this was due to a WM, are you sure it was Emacs that was eating up > memory, and not the WM itself? More often I could not do anything. So I have just hard reset computer without shutdown. For some reason not even the Magic SysRq key was enabled on Hyperbola GNU/Linux-libre, so I have enabled that one to at least synchronize disk data and unmount disks before the rest. How I know it was Emacs? I do not know, I am just assuming. I was using almost exclusively Emacs and sometimes sxiv image viewer which exits after viewing and browser. Then I switched to console and tried killing browser to see if system becomes responsive. Killing any other program did not make system responsive, so only killing Emacs gave me back responsiveness. Provided I could switch to console as responsiveness was terrible. From maybe 20 times I could switch maybe few times to console to actually get responsiveness. This happened more than 20 times and I was using symon-mode to monitor swapping. When I have seen that swapping is few gigabytes for no good reason I have tried killing everything to understand what is going on. I've end up killing Emacs and EXWM and restarting X to get into good shape. Because it was tedious over weeks not to be able to rely on computer under EXWM, I have switched to IceWM which is familiar to me. And I did not encounter anything like that regardless how long Emacs runs. Now after discussion of other bug where you suggested limiting rss and after limiting rss I could invoke ./a.out and get prompt, and maybe that ulimit -m or other tweaking could stop that type of behavior. I have to look into it. It could be again that Emacs is not responsible for that but rather liberal system settings. > If it was Emacs, then I think the only way it could depend on the WM > is if the WM feeds Emacs with many X events that somehow consume > memory. I was thinking to report to EXWM but I am unsure why it is happening and cannot easily find out what is really swapping. But because I used often Emacs exclusively that is how I know that it has to be Emacs swapping.