aboutsummaryrefslogtreecommitdiff
path: root/block/qcow2.h
diff options
context:
space:
mode:
authorVladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>2018-06-20 17:48:37 +0300
committerKevin Wolf <kwolf@redhat.com>2018-07-05 10:29:19 +0200
commitceb029cd6feccf9f7607833b71dd609d149421a1 (patch)
treeff8c0d61b29e1267c912ae2d2a7a8abedf980f13 /block/qcow2.h
parent2714f13d69adf73638842729ccfb3bdd6d5ee98f (diff)
qcow2: add compress threads
Do data compression in separate threads. This significantly improve performance for qemu-img convert with -W (allow async writes) and -c (compressed) options. Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Diffstat (limited to 'block/qcow2.h')
-rw-r--r--block/qcow2.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/block/qcow2.h b/block/qcow2.h
index 1c9c0d3631..d6aca687d6 100644
--- a/block/qcow2.h
+++ b/block/qcow2.h
@@ -326,6 +326,9 @@ typedef struct BDRVQcow2State {
* override) */
char *image_backing_file;
char *image_backing_format;
+
+ CoQueue compress_wait_queue;
+ int nb_compress_threads;
} BDRVQcow2State;
typedef struct Qcow2COWRegion {