From: Peter Lieven <pl@kamp.de>
To: "Daniel P. Berrange" <berrange@redhat.com>
Cc: qemu-block@nongnu.org, kwolf@redhat.com, qemu-devel@nongnu.org,
mreitz@redhat.com, den@openvz.org, lersek@redhat.com
Subject: Re: [Qemu-devel] [PATCH 4/4] block/qcow2: add zlib-fast compression algorithm
Date: Tue, 27 Jun 2017 15:23:19 +0200 [thread overview]
Message-ID: <ede8e3d7-7980-e065-e329-e35c988faaf0@kamp.de> (raw)
In-Reply-To: <20170627131605.GG13634@redhat.com>
Am 27.06.2017 um 15:16 schrieb Daniel P. Berrange:
> On Tue, Jun 27, 2017 at 02:34:10PM +0200, Peter Lieven wrote:
>> this adds support for optimized zlib settings which almost
>> tripples the compression speed while maintaining about
>> the same compressed size.
>>
>> Signed-off-by: Peter Lieven <pl@kamp.de>
>> ---
>> block/qcow2-cluster.c | 3 ++-
>> block/qcow2.c | 11 +++++++++--
>> block/qcow2.h | 1 +
>> qemu-img.texi | 1 +
>> 4 files changed, 13 insertions(+), 3 deletions(-)
>> diff --git a/qemu-img.texi b/qemu-img.texi
>> index 043c1ba..83a5db2 100644
>> --- a/qemu-img.texi
>> +++ b/qemu-img.texi
>> @@ -627,6 +627,7 @@ The following options are available if support for the respective libraries
>> has been enabled at compile time:
>>
>> zlib Uses standard zlib compression (default)
>> + zlib-fast Uses zlib compression with optimized compression parameters
> This looks like a poor design from a future proofing POV. I would much
> rather see us introduce a more flexible modelling of compression at the
> QAPI layer which lets us have tunables for each algorith, in the same
> way that the qcow2 built-in encryption now has ability to set tunables
> for each algorithm.
>
> eg your "zlib-fast" impl which just uses zlib with a window size of -15
> could be expressed as
>
> qemu-img create -o compress.format=zlib,compress.window=-15
It would also need a compress.level, but okay. This will make things
more complicated as one might not know what good values for
the algoritm are.
Wouldn't it be better to have sth like compress.level=1..9 and let
the implementation decide which parameters it choose for the algorithm?
Do you have a pointer where I can find out how to imlement that
in QAPI? Maybe the patches that introduces the encryption settings?
Thanks,
Peter
next prev parent reply other threads:[~2017-06-27 13:23 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-06-27 12:34 [Qemu-devel] [PATCH 0/4] block/qcow2: add compression_algorithm create option Peter Lieven
2017-06-27 12:34 ` [Qemu-devel] [PATCH 1/4] " Peter Lieven
2017-06-27 12:49 ` Eric Blake
2017-06-27 14:49 ` Peter Lieven
2017-06-27 15:04 ` Eric Blake
2017-06-27 15:11 ` Peter Lieven
2017-06-27 15:13 ` Peter Lieven
2017-07-03 19:45 ` Peter Lieven
2017-06-27 13:20 ` Daniel P. Berrange
2017-06-27 13:27 ` Peter Lieven
2017-06-28 14:50 ` Denis V. Lunev
2017-06-28 14:54 ` Denis V. Lunev
2017-06-27 12:34 ` [Qemu-devel] [PATCH 2/4] block/qcow2: optimize qcow2_co_pwritev_compressed Peter Lieven
2017-06-27 12:34 ` [Qemu-devel] [PATCH 3/4] block/qcow2: add lzo compression algorithm Peter Lieven
2017-06-27 12:34 ` [Qemu-devel] [PATCH 4/4] block/qcow2: add zlib-fast " Peter Lieven
2017-06-27 12:53 ` Eric Blake
2017-06-27 13:14 ` Peter Lieven
2017-06-27 13:16 ` Daniel P. Berrange
2017-06-27 13:23 ` Peter Lieven [this message]
2017-06-27 13:46 ` Daniel P. Berrange
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=ede8e3d7-7980-e065-e329-e35c988faaf0@kamp.de \
--to=pl@kamp.de \
--cc=berrange@redhat.com \
--cc=den@openvz.org \
--cc=kwolf@redhat.com \
--cc=lersek@redhat.com \
--cc=mreitz@redhat.com \
--cc=qemu-block@nongnu.org \
--cc=qemu-devel@nongnu.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.
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.