From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Po Lu Newsgroups: gmane.emacs.devel Subject: Re: Memory problems update Date: Fri, 23 Sep 2022 08:29:22 +0800 Message-ID: <87zgerc4rh.fsf@yahoo.com> References: <87v8pz18wf.fsf@mail.jao.io> <83o7vrgimc.fsf@gnu.org> <87wnafdnee.fsf@logand.com> <835yhzgdyi.fsf@gnu.org> <87k06den1s.fsf@logand.com> <87illxy5ir.fsf@mail.jao.io> <87sfl1d1wi.fsf@logand.com> <87czc5y1wp.fsf@mail.jao.io> <871qsl8gt4.fsf@yahoo.com> <87v8pfwc1z.fsf@mail.jao.io> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="20616"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.91 (gnu/linux) Cc: emacs-devel@gnu.org To: Jose Antonio Ortega Ruiz Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri Sep 23 02:31:57 2022 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 1obWbi-0005GG-8k for ged-emacs-devel@m.gmane-mx.org; Fri, 23 Sep 2022 02:31:54 +0200 Original-Received: from localhost ([::1]:59700 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1obWbh-00005i-5s for ged-emacs-devel@m.gmane-mx.org; Thu, 22 Sep 2022 20:31:53 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:56288) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1obWZq-0007KD-0r for emacs-devel@gnu.org; Thu, 22 Sep 2022 20:29:58 -0400 Original-Received: from sonic311-25.consmr.mail.ne1.yahoo.com ([66.163.188.206]:44664) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1obWZn-0004Sd-4a for emacs-devel@gnu.org; Thu, 22 Sep 2022 20:29:57 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1663892974; bh=QzXmOmVmGBoVUkCUGvL/H0vTff3Nk/k6bF1tdpgwWus=; h=From:To:Cc:Subject:References:Date:In-Reply-To:From:Subject:Reply-To; b=Rt+XL4B4SeJe7cpMW3u/aP7sl/fb+Zej+TibOMwq4EYLtqjXQ2ou6fMRwFcBPBIMUYmGvPxwXrEA/5Kd2R7aGcVWC3Okot4Ra/SNPcjeqvUAn7p6agm2cvOd90xR4mWcgiikYhX+u5Bkd7eOb82EhpcLaFU8+gRp7Tl2rnV3BWpkb7NltTKaegnmXVRtakoKSWsCII6jJDbjcMuw5yKggpWFEKIvsIWFjwmH4EguX3RrHLlaOpfW4gjj4t9UOoix7S22wlAgZqvv8v6Wd1JW3dTG7FEJesmoBGzqpAvak16Fd0KTKG0X5qALkyaz2Q0FwNY1i5ewUQy1WK+RGDPyXA== X-SONIC-DKIM-SIGN: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1663892974; bh=feOYyK4NEDV48/XYduA3WcAquzn+mH5tkPjfTadAkSb=; h=X-Sonic-MF:From:To:Subject:Date:From:Subject; b=LjaIXcfH0tlgoBiAjuzvTQIfcuXEw0DDKnpKNwhvZ0vgLU9ZuWAPmUY2LJgYtA4mR3rdxz6pFJESRdulakP89URoL0V0q9LG8JyReWnjmCi0oYpFLj3IadH06/WFTEoacVgNvjNc3CldzsqmOIOKD8NeyVNMi/8F5033nIuhhKpSR9ZNUQ97ZUVjf8uSY1CBXtfOelrKsu/yerSq7ae31/MKmqFYxD0g4/SYyBARMQUeBA3ax0gbH+BI9edarhWhV5MsdfkXk3u41BHrziRSvXA0d+88GEN/uYRnvD1Aji9IDklYtI1oOF+R66EZmtnmAK+D/AXnd6/TAyi7fn2EiQ== X-YMail-OSG: caeAeRsVM1nD_wXllQsT_hkN5vU4IMl4SbsAN.MV4Hqvof959A7N3iNIcBsOaBo jcIEnxWTdmTFj.hmySFn2s2HUWNdqj6q8K.z51HldfxDPF4UFOa3wyCGIVQBkif5oqaeTKkQYkGl 6Cjx13zGO1d9KnChtdYsLJtIQ8d6yGQ54smZCV87k9Vnh0WSP6HOOnaymaRIlz1a0QiJElLKHvCr VyMvN0M01GxfbbA8QOguSi1NAIgqySNIi9QWtHMw16H0AS6XYhDWlueLpJLtA7Ed1p3d7LBOeqWl 9MmyY7CWNSAbMeAywuiMo.eB3qv73mypgkP7bLNcbutcxsDqlWgDZqGdotY01yBl0WS3tmU6vZZr E9aN.fAhkkudMFR9ftFa01N6bFQy0xFH9JKizmd6VxOx8yiGDjfaprgSEJ1zai5GjlojXOc2H05z Fi3WAYC8HWKDUHJS08OwTMD9sCDljn3AL1nCcP38RbL2FEdMsLtXVKzQN6RxUtO8XM5AM9XWTVVH qkf2BKf8_dAcVbFUqQtotj_eZPgTNQulrf2KqHwoWBkKJM8THIBQXAWAUSwS2_.gbB1YU7O_xNi6 rwXPYGmzjCqr31P.enkM0h5IyONF7LXyW2KPS3HooJm14YzY8qWIOrBAok43SnSZnaQhu9cC21Lv 6gQTXWT4qGU_MT2jOJQ5qZnwsnl75qExFyetMlGE6GWzLksWXxaCkM4noGvUIiN8hCSCEVKfkgAF EgpcDFXg.bjRgrcIjcQJpjkrWHZUU_ykJph.6O6F.1pIbOCxrt8RlOceTFvJZhyRrnfBXxI8N3O. KFKRbxz_6CS1ZlU3tCvWwkMl0UZJyGsaApbwTTq4ox X-Sonic-MF: Original-Received: from sonic.gate.mail.ne1.yahoo.com by sonic311.consmr.mail.ne1.yahoo.com with HTTP; Fri, 23 Sep 2022 00:29:34 +0000 Original-Received: by hermes--production-sg3-dfffdfbd4-v2h7k (Yahoo Inc. Hermes SMTP Server) with ESMTPA ID a52752f38f983328f3e4cf9f0dcbb299; Fri, 23 Sep 2022 00:29:28 +0000 (UTC) In-Reply-To: <87v8pfwc1z.fsf@mail.jao.io> (Jose Antonio Ortega Ruiz's message of "Thu, 22 Sep 2022 18:31:36 +0100") X-Mailer: WebService/1.1.20663 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.yahoo Received-SPF: pass client-ip=66.163.188.206; envelope-from=luangruo@yahoo.com; helo=sonic311-25.consmr.mail.ne1.yahoo.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=unavailable autolearn_force=no X-Spam_action: no action 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" Xref: news.gmane.io gmane.emacs.devel:296014 Archived-At: Jose Antonio Ortega Ruiz writes: > I finally did, and, under X11 (non-toolkit build), things have indeed > improved drastically. With my full configuration, Emacs went down to > allocating "only" ~100Mb per day with that fix. Then, just on a whim, i > tried to disable a trick i use to hide the modelines, by altering their > faces like this (yes, it's a dirty hack, and i'm probably missing a > better way): > > (let ((bg (frame-parameter nil 'background-color)) > (ol "burlywood3") > (ul "grey65")) > (set-face-attribute 'mode-line nil :box nil :height 1 > :background bg :foreground bg > :overline ol :underline ul :extend t) > (set-face-attribute 'mode-line-inactive nil :box nil :height 1 > :background bg :foreground bg > :underline ul :extend t))) > > now, when i do *not* use the above code, extra RAM per day goes down > from 100Mb to less than 20Mb. Does that make any sense? Maybe it's a > red-herring. > > So, in X11, i am much happier: things stabilise at around 700Mb, with > only small increments, and i can also see Emacs returning memory to the > system every now and then. Right. I can't say as to whether or not that was the leak in `mouse-position', but if it stabilises then I guess it isn't a problem anymore. > Unfortunately, the situation with the pgtk build has not improved at > all. I actually think it's gone worse since i last tried: a pgtk emacs > running in wayland (i've tried with sway and river) goes up to a 2Gb > footprint in just a couple hours of use (and shows no sign of stopping). > So there i stick to tty emacs in kitty or foot (BTW, i think the bug fix > you mention above also affected tty emacs, because it's also consuming > around 25% less memory than it used to). That's quite odd, but I suspect a memory fragmentation issue if you have lots of frames (or child frames) and frequently resize them. What if you turn off all packages that utilize child frames?