Problem with C++ wrapper and gpgme
Marcus Brinkmann
Marcus.Brinkmann at ruhr-uni-bochum.de
Fri Jun 6 06:48:02 CEST 2003
On Mon, Jun 02, 2003 at 10:06:23PM +0400, Yenot wrote:
> The combination of the older GnuPG and the rebuild of the keydb is
> yielding much better results:
> real 0.28
> user 0.25
> sys 0.02
I have just made some numbers with the soon to be released GPGME 0.4.1:
All times in seconds.
Program real user sys
gpg --export 0.240 0.240 0.000
gpg --list-keys 0.304 0.290 0.010 (--with-colons --fixed-list-mode etc)
gpgme 0.4.1 0.326 0.000 0.010
This is with 159 keys. Now, one can say that using gpgme is 35% slower than
exporting the key data in raw format. However, GPGME provides the key data
in convenient C structs for direct access. A real comparison would have to
be done with larger keyrings and against a program that actually takes the
--export data and converts it into something like what GPGME provides. This
would likely still be faster, probably in the 0.260 - 0.265 range (0.010 would
be needed to get the output over a pipe into your program, and then whatever it
requires to parse the data and set up the data structures). However, a 25%
slow down is not too bad and should be acceptable for many applications, and
thus I think that GPGME is, as a general purpose library, in pretty good shape.
Especially if you consider that GPGME has not been optimized at all yet.
In the future, the protocol between GPG and GPGME could also be further
optimized to allow for faster key structure generation. I think it would be
more useful to work on eliminating bottle necks in the existing system than
to reimplement it.
Thanks,
Marcus
--
`Rhubarb is no Egyptian god.' GNU http://www.gnu.org marcus at gnu.org
Marcus Brinkmann The Hurd http://www.gnu.org/software/hurd/
Marcus.Brinkmann at ruhr-uni-bochum.de
http://www.marcus-brinkmann.de/
More information about the Gnupg-devel
mailing list