gpg --list-keys performance [was: Re: GnuPG 2.1.2 making tons of syscalls]
Daniel Kahn Gillmor
dkg at fifthhorseman.net
Wed Apr 1 00:43:35 CEST 2015
On Mon 2015-03-30 08:07:38 -0400, Guilhem Moulin wrote:
> On Wed, 25 Feb 2015 at 10:14:20 +0100, Guilhem Moulin wrote:
>> $ time gpg --homedir /tmp/gnupg1 --list-sigs >/dev/null
>> 1:57.54 (83.55 user, 33.57 sys) 9264k maxres
>> $ time gpg2 --homedir /tmp/gnupg2 --list-sigs >/dev/null
>> 2:24:34 (564.61 user, 8083.49 sys) 14936k maxres
>> The second timming is really odd: over 2h of system time? Surely it
>> must be a bug.
>> $ time gpg --homedir /tmp/gnupg1 --list-sigs 0x39278DA8109E6244 >/dev/null
>> 0:17.24 (11.72 user, 5.46 sys) 8852k maxres
>> $ time gpg2 --homedir /tmp/gnupg2 --list-sigs 0x39278DA8109E6244 >/dev/null
>> 0:30.85 (3.26 user, 27.50 sys) 14564k maxres
> Doesn't anyone acknowledge this behavior and the fact that it's a bug?
> I can't believe all these syscalls are intended, somehow. Incidentally,
> Jesus Cea made a similar observation (with 2.0.27) when updating the
I'm seeing the same behavior you're seeing, and yes, it seems like a
I also see that you've opened a related bug report here:
maybe it would be good to file separate bug reports for each specific
issue so we can track them down? the TL;DR of your initial post had a
number of good independent details.
Have you tried profiling the extremely slow invocations with "valgrind
--tool=callgrind" ? that might yield some hints about where to start
fixing the problem.
More information about the Gnupg-devel