Re: [RFC] thread-pool: Add option to fix the pool size

2022-02-14 Thread Kevin Wolf
Am 14.02.2022 um 14:10 hat Stefan Hajnoczi geschrieben: > On Mon, Feb 14, 2022 at 12:38:22PM +0100, Kevin Wolf wrote: > > Am 14.02.2022 um 11:09 hat Stefan Hajnoczi geschrieben: > > > On Fri, Feb 11, 2022 at 12:32:57PM +0100, Kevin Wolf wrote: > > > > Am 03.02.2022 um 15:19 hat Stefan Hajnoczi gesc

Re: [RFC] thread-pool: Add option to fix the pool size

2022-02-14 Thread Stefan Hajnoczi
On Mon, Feb 14, 2022 at 12:38:22PM +0100, Kevin Wolf wrote: > Am 14.02.2022 um 11:09 hat Stefan Hajnoczi geschrieben: > > On Fri, Feb 11, 2022 at 12:32:57PM +0100, Kevin Wolf wrote: > > > Am 03.02.2022 um 15:19 hat Stefan Hajnoczi geschrieben: > > > > On Thu, Feb 03, 2022 at 10:56:49AM +, Danie

Re: [RFC] thread-pool: Add option to fix the pool size

2022-02-14 Thread Kevin Wolf
Am 14.02.2022 um 11:09 hat Stefan Hajnoczi geschrieben: > On Fri, Feb 11, 2022 at 12:32:57PM +0100, Kevin Wolf wrote: > > Am 03.02.2022 um 15:19 hat Stefan Hajnoczi geschrieben: > > > On Thu, Feb 03, 2022 at 10:56:49AM +, Daniel P. Berrangé wrote: > > > > On Thu, Feb 03, 2022 at 10:53:07AM +000

Re: [RFC] thread-pool: Add option to fix the pool size

2022-02-14 Thread Stefan Hajnoczi
On Fri, Feb 11, 2022 at 12:32:57PM +0100, Kevin Wolf wrote: > Am 03.02.2022 um 15:19 hat Stefan Hajnoczi geschrieben: > > On Thu, Feb 03, 2022 at 10:56:49AM +, Daniel P. Berrangé wrote: > > > On Thu, Feb 03, 2022 at 10:53:07AM +, Stefan Hajnoczi wrote: > > > > On Wed, Feb 02, 2022 at 06:52:

Re: [RFC] thread-pool: Add option to fix the pool size

2022-02-11 Thread Kevin Wolf
Am 03.02.2022 um 15:19 hat Stefan Hajnoczi geschrieben: > On Thu, Feb 03, 2022 at 10:56:49AM +, Daniel P. Berrangé wrote: > > On Thu, Feb 03, 2022 at 10:53:07AM +, Stefan Hajnoczi wrote: > > > On Wed, Feb 02, 2022 at 06:52:34PM +0100, Nicolas Saenz Julienne wrote: > > > > The thread pool re

Re: [RFC] thread-pool: Add option to fix the pool size

2022-02-11 Thread Nicolas Saenz Julienne
On Thu, 2022-02-03 at 14:19 +, Stefan Hajnoczi wrote: > Yep, I didn't comment on this because I don't have a good suggestion. > > In terms of semantics I think we should have: > > 1. A global default value that all new AioContext take. The QEMU main >loop's qemu_aio_context will use this

Re: [RFC] thread-pool: Add option to fix the pool size

2022-02-07 Thread Stefan Hajnoczi
On Mon, Feb 07, 2022 at 01:00:46PM +0100, Nicolas Saenz Julienne wrote: > Hi Stefan, thanks for the review. I took note of your comments. > > On Thu, 2022-02-03 at 10:53 +, Stefan Hajnoczi wrote: > > > Some background on my workload: I'm using IDE emulation, the guest is an > > > old RTOS that

Re: [RFC] thread-pool: Add option to fix the pool size

2022-02-07 Thread Nicolas Saenz Julienne
Hi Stefan, thanks for the review. I took note of your comments. On Thu, 2022-02-03 at 10:53 +, Stefan Hajnoczi wrote: > > Some background on my workload: I'm using IDE emulation, the guest is an > > old RTOS that doesn't support virtio, using 'aio=native' isn't possible > > either (unaligned I

Re: [RFC] thread-pool: Add option to fix the pool size

2022-02-03 Thread Stefan Hajnoczi
On Thu, Feb 03, 2022 at 10:56:49AM +, Daniel P. Berrangé wrote: > On Thu, Feb 03, 2022 at 10:53:07AM +, Stefan Hajnoczi wrote: > > On Wed, Feb 02, 2022 at 06:52:34PM +0100, Nicolas Saenz Julienne wrote: > > > The thread pool regulates itself: when idle, it kills threads until > > > empty, w

Re: [RFC] thread-pool: Add option to fix the pool size

2022-02-03 Thread Daniel P . Berrangé
On Thu, Feb 03, 2022 at 10:53:07AM +, Stefan Hajnoczi wrote: > On Wed, Feb 02, 2022 at 06:52:34PM +0100, Nicolas Saenz Julienne wrote: > > The thread pool regulates itself: when idle, it kills threads until > > empty, when in demand, it creates new threads until full. This behaviour > > doesn't

Re: [RFC] thread-pool: Add option to fix the pool size

2022-02-03 Thread Stefan Hajnoczi
On Wed, Feb 02, 2022 at 06:52:34PM +0100, Nicolas Saenz Julienne wrote: > The thread pool regulates itself: when idle, it kills threads until > empty, when in demand, it creates new threads until full. This behaviour > doesn't play well with latency sensitive workloads where the price of > creating

[RFC] thread-pool: Add option to fix the pool size

2022-02-02 Thread Nicolas Saenz Julienne
The thread pool regulates itself: when idle, it kills threads until empty, when in demand, it creates new threads until full. This behaviour doesn't play well with latency sensitive workloads where the price of creating a new thread is too high. For example, when paired with qemu's '-mlock', or usi