qemu-block
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

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


From: Nicolas Saenz Julienne
Subject: Re: [RFC] thread-pool: Add option to fix the pool size
Date: Fri, 11 Feb 2022 10:30:13 +0100
User-agent: Evolution 3.42.3 (3.42.3-1.fc35)

On Thu, 2022-02-03 at 14:19 +0000, 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 and all IOThread AioContext
>    will use it (unless they have been overridden).
> 
>    I would define it on --machine because that's the "global" object for
>    a guest, but that's not very satisfying.

So I tried to implement this. One problem arouse:
 - The thread pool properties are now part of the MachineState. So as to
   properly use QOM.
 - Sadly, the main loop is initialized before the machine class options are
   populated. See 'qemu_init_main_loop()' and 'qemu_apply_machine_options()' in
   'softmmu/vl.c'.
 - Short of manually parsing the options, which IMO defeats the purpose of
   using QOM, or changing the initialization order, which I'm sure won't be
   easy, I can't access the properties early enough.

Any ideas?

Thanks!

-- 
Nicolás Sáenz




reply via email to

[Prev in Thread] Current Thread [Next in Thread]