Subject: Re: bug#13795: 24.3.50; epa-insert-keys improvements

From: Lars Ingebrigtsen <[email-masked]>
Date: Mon, 07 Dec 2020 16:11:26 +0100

Richard Stallman <[email-masked]> writes:

> I am running master from June.  epa-insert-keys just took 6 seconds
> to insert 700 keys.  I still have a build of master from Oct 2019;
> epa-insert-keys took the same time in that version.

Yes, that sounds uncomfortably slow.

Hm...  is there any way to inject hundreds of keys into the key ring to
make it easier to test what part of this is taking time.  Anybody know?

If it's external (i.e., the gpg tools are slow), then we should cache
the results -- otherwise we should fix the code on the Emacs side to be
faster.

> It could save the text in a file, and compare that file's mtime with
> that of the keyring to see whether to regenerate the file.  That way,
> the memoization will work from one Emacs session to another.

I think caching the data in a file would be more bother than it's worth,
but we could certainly cache the data in-memory during an Emacs session.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no