From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Lars Ingebrigtsen Newsgroups: gmane.emacs.bugs Subject: bug#33275: 27.0.50; Image cache pruning Date: Mon, 05 Nov 2018 18:48:33 +0100 Message-ID: References: <83va5bcxxu.fsf@gnu.org> <83sh0fcx2r.fsf@gnu.org> <83o9b3cu4f.fsf@gnu.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1541440035 15805 195.159.176.226 (5 Nov 2018 17:47:15 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Mon, 5 Nov 2018 17:47:15 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) Cc: 33275@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Nov 05 18:47:10 2018 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gJixy-00040b-2Y for geb-bug-gnu-emacs@m.gmane.org; Mon, 05 Nov 2018 18:47:10 +0100 Original-Received: from localhost ([::1]:36763 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gJj04-0004pa-Ea for geb-bug-gnu-emacs@m.gmane.org; Mon, 05 Nov 2018 12:49:20 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:51883) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gJizu-0004pC-A0 for bug-gnu-emacs@gnu.org; Mon, 05 Nov 2018 12:49:14 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gJizp-0002bN-Rc for bug-gnu-emacs@gnu.org; Mon, 05 Nov 2018 12:49:10 -0500 Original-Received: from debbugs.gnu.org ([208.118.235.43]:59530) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gJizm-0002OE-GU for bug-gnu-emacs@gnu.org; Mon, 05 Nov 2018 12:49:04 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1gJizm-0006pu-EK for bug-gnu-emacs@gnu.org; Mon, 05 Nov 2018 12:49:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Lars Ingebrigtsen Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 05 Nov 2018 17:49:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 33275 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 33275-submit@debbugs.gnu.org id=B33275.154144013326264 (code B ref 33275); Mon, 05 Nov 2018 17:49:02 +0000 Original-Received: (at 33275) by debbugs.gnu.org; 5 Nov 2018 17:48:53 +0000 Original-Received: from localhost ([127.0.0.1]:35555 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gJizZ-0006pU-DN for submit@debbugs.gnu.org; Mon, 05 Nov 2018 12:48:53 -0500 Original-Received: from ryder.getmail.no ([84.210.184.14]:35254) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gJizU-0006oy-Dc for 33275@debbugs.gnu.org; Mon, 05 Nov 2018 12:48:48 -0500 Original-Received: from localhost (localhost [127.0.0.1]) by ryder.getmail.no (Postfix) with ESMTP id 49F5262C86; Mon, 5 Nov 2018 18:48:34 +0100 (CET) Original-Received: from ryder.getmail.no ([127.0.0.1]) by localhost (ryder.get.c.bitbit.net [127.0.0.1]) (amavisd-new, port 10032) with ESMTP id 4LTxwgA4gwGJ; Mon, 5 Nov 2018 18:48:33 +0100 (CET) Original-Received: from localhost (localhost [127.0.0.1]) by ryder.getmail.no (Postfix) with ESMTP id CDA8F62C87; Mon, 5 Nov 2018 18:48:33 +0100 (CET) X-Virus-Scanned: amavisd-new at ryder.getmail.no Original-Received: from ryder.getmail.no ([127.0.0.1]) by localhost (ryder.get.c.bitbit.net [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id YDlDPCmlSzp3; Mon, 5 Nov 2018 18:48:33 +0100 (CET) Original-Received: from stories (cm-84.212.221.165.getinternet.no [84.212.221.165]) by ryder.getmail.no (Postfix) with ESMTPSA id A2BF862C86; Mon, 5 Nov 2018 18:48:33 +0100 (CET) Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAAGFBMVEW6gTlVGIFdHox+SDZD EmhXGoJRFnz8xUXqvZ6yAAACO0lEQVQ4jW2UzY+DIBDFaa3bM0a8S2rPJG7iVbvUO0Q8S4NzbtKD //4OoK2bLP1I01/ePN4wQsBo/t8iBdX/IjIyzTUH6Yquu1wenF+rWwDK6IpzJ9fFr73rV0WGlVzv 4NYNQbGWUoYpzuUPea/vewBGzYbry5Scl+d5we8ljR6mmtF9mGqRvAR5EdGc+hVYzpVr67p+hXdz vFUeaMN0VSBAxQZ4BHNmrAf4r2fNocNgHlhuQEbwRwFQMcgnEsyfQmzAWKqYzdvlvb56ju4EwDJr 5Q6gwnuABcOyy/QtMdtCPIjmwGBmWd4KQYSoSf1qTjJ4OABgmUOQkAZB0qS9YbEU2McwiXYDXz3N gjnM5q1IEJzkCizzyT8g7SieKilgBkvzCYGIAEtRHRRWKa+oxVZqxFreA8ZZtqL2wJsfu5JtwObT spxD7ldzkAVl5q1I6giei/fIqhAQGJ7HD4kdWdJebR4Acbt4JqG7JTUbQPN2A6mk2BNiLX0rsI8e YMBQCoHNA8DsCLAlJgQsEMjoQWIpFZOz0Vo3fcCxi8DSwlLnzUUEviU67spirwg5n9czxxzrdmcz tFtLfKmg8Mkt24/PSZZMmwBmjaVEnSTE9yS9lVT7Xo3A2OBz15hkNz6Yg9KhfYYOPkOpyqxgVvtJ TPtKr9t9mGH6gEPPowIKzfPdw/kVJ9EDRsfHHS7j7X65Ph7XfgNWfy4AvyKwOKJMDX3nXH7v3ICf YlMA0yX+rP5eMgEYpXc3UIWv8hctdBMsfua7RgAAAABJRU5ErkJggg== In-Reply-To: (Lars Ingebrigtsen's message of "Mon, 05 Nov 2018 18:36:39 +0100") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 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.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:152068 Archived-At: Lars Ingebrigtsen writes: > Or does Emacs have weak hashes? In which case the image cache could be > a weak hash and the problem would resolve itself? Emacs does have weak hashes... Hm... Anyway, there's code that tries to keep the cache small: /* If the number of cached images has grown unusually large, decrease the cache eviction delay (Bug#6230). */ delay = XFIXNUM (Vimage_cache_eviction_delay); if (nimages > 40) delay = 1600 * delay / nimages / nimages; But it works solely on the number of images in the cache, and not the size of the images. So it's a heuristic that could be tweaked pretty easily, I think? -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no