[Libguestfs] [PATCH 0/4] lib: qemu: Memoize qemu feature detection.

Richard W.M. Jones rjones at redhat.com
Thu May 12 21:26:21 UTC 2016


Doing qemu feature detection in the direct backend takes ~100ms
because we need to run `qemu -help' and `qemu -devices ?', and each of
those interacts with glibc's very slow link loader.

Fixing the link loader is really hard.  Instead memoize the
output of those two commands.

This patch series first separates all the code dealing with qemu into
a separate module (src/qemu.c) and formalizes the interface to this
module.  Then I had to rearrange the code we use to create
/var/tmp/.guestfs-<UID> for the supermin appliance to src/tmpdirs.c.
The final patch adds the memoization, storing this in the supermin
appliance cache directory.

Rich.




More information about the Libguestfs mailing list