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.bugs Subject: bug#43389: 28.0.50; Emacs memory leaks Date: Tue, 15 Sep 2020 21:52:45 +0300 Message-ID: <838sda98jm.fsf@gnu.org> References: <87r1r5428d.fsf@web.de> <87mu1sry72.fsf@mail.linkov.net> <875z8fc224.fsf@web.de> <20200915175418.GV20869@maokai> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="21518"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 43389@debbugs.gnu.org To: Russell Adams Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Sep 15 20:53:10 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 1kIG4j-0005Qv-FT for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 15 Sep 2020 20:53:09 +0200 Original-Received: from localhost ([::1]:38814 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kIG4i-00065U-GV for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 15 Sep 2020 14:53:08 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:39280) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kIG4c-00064c-57 for bug-gnu-emacs@gnu.org; Tue, 15 Sep 2020 14:53:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:49039) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kIG4b-0007kT-RP for bug-gnu-emacs@gnu.org; Tue, 15 Sep 2020 14:53:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kIG4b-0000F2-PF for bug-gnu-emacs@gnu.org; Tue, 15 Sep 2020 14:53:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 15 Sep 2020 18:53: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.1600195966904 (code B ref 43389); Tue, 15 Sep 2020 18:53:01 +0000 Original-Received: (at 43389) by debbugs.gnu.org; 15 Sep 2020 18:52:46 +0000 Original-Received: from localhost ([127.0.0.1]:60585 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kIG4M-0000EW-Dn for submit@debbugs.gnu.org; Tue, 15 Sep 2020 14:52:46 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:60580) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kIG4K-0000EH-OC for 43389@debbugs.gnu.org; Tue, 15 Sep 2020 14:52:45 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:51467) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kIG4E-0007hw-Fn; Tue, 15 Sep 2020 14:52:38 -0400 Original-Received: from [176.228.60.248] (port=1517 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kIG4D-0005lM-W2; Tue, 15 Sep 2020 14:52:38 -0400 In-Reply-To: <20200915175418.GV20869@maokai> (message from Russell Adams on Tue, 15 Sep 2020 19:54:18 +0200) 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:188149 Archived-At: > Date: Tue, 15 Sep 2020 19:54:18 +0200 > From: Russell Adams > > htop says my emacs RSS is now 5148MB. I ran M-x garbage-collect and it ran > at 100% cpu for 5 minutes and released nothing. I also tried manually > executing (clear-image-cache) and nothing. Can you use some utility that produces a memory map of an application, and see how much of those 5GB are actually free for allocation by Emacs? Also, do you see any libraries used by Emacs that have high memory usage? > I run Emacs 27.1 as a daemon, uptime 4 days, 3 hours, 22 minutes, 53 > seconds. Yesterday conki was reporting Emacs at 28% memory usage, > today it's at 33%. 28% and 33% of what amount? If your RSS is 5GB after 4 days of uptime, and the memory footprint grows at a constant rate, it would mean more than 1GB per day. But I'm guessing that 33% - 28% = 5% of your total memory is much less than 1GB. In which case the memory footprint must sometimes jump by very large amounts, not grow slowly and monotonically each day. Right? So which events cause those sudden increases in RSS? Also, what is your value of gc-cons-threshold, and do you have some customizations that change its value under some conditions? If so, please tell the details. Thanks.