all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Andreas Politz <politza@hochschule-trier.de>
To: Eli Zaretskii <eliz@gnu.org>
Cc: emacs-devel@gnu.org
Subject: AW: Re: Free images based on allocated memory
Date: Thu, 31 Jan 2019 18:33:28 +0100	[thread overview]
Message-ID: <0tnhgpyuoqjftuyshr72i1ng.1548956008081@email.android.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 941 bytes --]

Yes, I know about image eviction delay.  Also, I'm not really sure if what I was proposing is a good idea.

One goal in my package is it to display PDF pages quickly. 
There are 2 factors delaying this:  The actual rendering in the back-end (via poppler) and the loading of the image by Emacs.  

In order to limit this timespan, pages are speculative pre-rendered and pre-loaded. E.g. if page n is currently displayed, the user probably wants to view page n+1 next. This is implemented by filling  a LRU cache while Emacs is idle.

Note how this conflicts with a least-recently-displayed eviction strategy.

Of course this can be solved in Lisp, just not very elegantly.  I spare you the details.

Another extension point, which would help managing the image-cache in my case, would be the ability to flush images based on their data.  Note, this is currenly only supported for file based images.

Thanks for taking the time,
Andreas

[-- Attachment #2: Type: text/html, Size: 1240 bytes --]

             reply	other threads:[~2019-01-31 17:33 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-31 17:33 Andreas Politz [this message]
2019-01-31 20:14 ` AW: Re: Free images based on allocated memory Eli Zaretskii

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=0tnhgpyuoqjftuyshr72i1ng.1548956008081@email.android.com \
    --to=politza@hochschule-trier.de \
    --cc=eliz@gnu.org \
    --cc=emacs-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.