[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH v2 6/7] coroutine: drop qemu_coroutine_adjust_pool_s
From: |
Paolo Bonzini |
Subject: |
[Qemu-devel] [PATCH v2 6/7] coroutine: drop qemu_coroutine_adjust_pool_size |
Date: |
Tue, 2 Dec 2014 12:05:49 +0100 |
This is not needed anymore. The new TLS-based algorithm is adaptive.
Signed-off-by: Paolo Bonzini <address@hidden>
---
block/block-backend.c | 4 ----
include/block/coroutine.h | 10 ----------
qemu-coroutine.c | 4 ----
3 files changed, 18 deletions(-)
diff --git a/block/block-backend.c b/block/block-backend.c
index d0692b1..abf0cd1 100644
--- a/block/block-backend.c
+++ b/block/block-backend.c
@@ -260,9 +260,6 @@ int blk_attach_dev(BlockBackend *blk, void *dev)
blk_ref(blk);
blk->dev = dev;
bdrv_iostatus_reset(blk->bs);
-
- /* We're expecting I/O from the device so bump up coroutine pool size */
- qemu_coroutine_adjust_pool_size(COROUTINE_POOL_RESERVATION);
return 0;
}
@@ -290,7 +287,6 @@ void blk_detach_dev(BlockBackend *blk, void *dev)
blk->dev_ops = NULL;
blk->dev_opaque = NULL;
bdrv_set_guest_block_size(blk->bs, 512);
- qemu_coroutine_adjust_pool_size(-COROUTINE_POOL_RESERVATION);
blk_unref(blk);
}
diff --git a/include/block/coroutine.h b/include/block/coroutine.h
index 793df0e..20c027a 100644
--- a/include/block/coroutine.h
+++ b/include/block/coroutine.h
@@ -216,14 +216,4 @@ void coroutine_fn co_aio_sleep_ns(AioContext *ctx,
QEMUClockType type,
*/
void coroutine_fn yield_until_fd_readable(int fd);
-/**
- * Add or subtract from the coroutine pool size
- *
- * The coroutine implementation keeps a pool of coroutines to be reused by
- * qemu_coroutine_create(). This makes coroutine creation cheap. Heavy
- * coroutine users should call this to reserve pool space. Call it again with
- * a negative number to release pool space.
- */
-void qemu_coroutine_adjust_pool_size(int n);
-
#endif /* QEMU_COROUTINE_H */
diff --git a/qemu-coroutine.c b/qemu-coroutine.c
index aee1017..ca40f4f 100644
--- a/qemu-coroutine.c
+++ b/qemu-coroutine.c
@@ -144,7 +144,3 @@ void coroutine_fn qemu_coroutine_yield(void)
self->caller = NULL;
coroutine_swap(self, to);
}
-
-void qemu_coroutine_adjust_pool_size(int n)
-{
-}
--
2.1.0
- [Qemu-devel] [PATCH v2 1/7] coroutine-ucontext: use __thread, (continued)
- [Qemu-devel] [PATCH v2 1/7] coroutine-ucontext: use __thread, Paolo Bonzini, 2014/12/02
- [Qemu-devel] [PATCH v2 2/7] qemu-thread: add per-thread atexit functions, Paolo Bonzini, 2014/12/02
- [Qemu-devel] [PATCH v2 4/7] QSLIST: add lock-free operations, Paolo Bonzini, 2014/12/02
- [Qemu-devel] [PATCH v2 3/7] test-coroutine: avoid overflow on 32-bit systems, Paolo Bonzini, 2014/12/02
- [Qemu-devel] [PATCH v2 5/7] coroutine: rewrite pool to avoid mutex, Paolo Bonzini, 2014/12/02
[Qemu-devel] [PATCH v2 6/7] coroutine: drop qemu_coroutine_adjust_pool_size,
Paolo Bonzini <=
[Qemu-devel] [PATCH v2 7/7] coroutine: try harder not to delete coroutines, Paolo Bonzini, 2014/12/02
Re: [Qemu-devel] [PATCH v2 0/7] coroutine: optimizations, Peter Lieven, 2014/12/11
Re: [Qemu-devel] [PATCH v2 0/7] coroutine: optimizations, Fam Zheng, 2014/12/18