[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v3 1/3] thread-pool: optimize scheduling of completion bottom
From: |
Stefan Hajnoczi |
Subject: |
Re: [PATCH v3 1/3] thread-pool: optimize scheduling of completion bottom half |
Date: |
Tue, 17 May 2022 16:20:06 +0100 |
On Sat, May 14, 2022 at 08:50:10AM +0200, Paolo Bonzini wrote:
> The completion bottom half was scheduled within the pool->lock
> critical section. That actually results in worse performance,
> because the worker thread can run its own small critical section
> and go to sleep before the bottom half starts running.
>
> Note that this simple change does not produce an improvement without
> changing the thread pool QemuSemaphore to a condition variable.
>
> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
> ---
> util/thread-pool.c | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
signature.asc
Description: PGP signature
[PATCH v3 3/3] thread-pool: remove stopping variable, Paolo Bonzini, 2022/05/14
Re: [PATCH v3 0/3] thread-pool: fix performance regression, Nicolas Saenz Julienne, 2022/05/17