qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Claudio Fontana <cfontana@suse.de>
To: "Philippe Mathieu-Daudé" <philmd@redhat.com>,
	"Paolo Bonzini" <pbonzini@redhat.com>,
	"Thomas Huth" <thuth@redhat.com>,
	"Alex Bennée" <alex.bennee@linaro.org>,
	"Peter Maydell" <peter.maydell@linaro.org>
Cc: Laurent Vivier <lvivier@redhat.com>,
	Eduardo Habkost <ehabkost@redhat.com>,
	Colin Xu <colin.xu@intel.com>,
	Marcelo Tosatti <mtosatti@redhat.com>,
	qemu-devel@nongnu.org, Roman Bolshakov <r.bolshakov@yadro.com>,
	haxm-team@intel.com, Wenchao Wang <wenchao.wang@intel.com>,
	Sunil Muthuswamy <sunilmut@microsoft.com>,
	Richard Henderson <rth@twiddle.net>
Subject: Re: [RFC v3 2/4] cpu-throttle: new module, extracted from cpus.c
Date: Mon, 25 May 2020 17:42:27 +0200	[thread overview]
Message-ID: <c1387681-fe93-d42b-c2b6-40b91c6801f1@suse.de> (raw)
In-Reply-To: <99995c3f-68a3-ce07-72bb-37a9b2263e52@redhat.com>

On 5/25/20 5:14 PM, Philippe Mathieu-Daudé wrote:
> On 5/25/20 4:54 PM, Claudio Fontana wrote:
>> move the vcpu throttling functionality into its own module.
>>
>> This functionality is not specific to any accelerator,
>> and it is used currently by migration to slow down guests to try to
>> have migrations converge, and by the cocoa MacOS UI to throttle speed.
>>
>> cpu-throttle contains the controls to adjust and inspect throttle
>> settings, start (set) and stop vcpu throttling, and the throttling
>> function itself that is run periodically on vcpus to make them take a nap.
>>
>> Execution of the throttling function on all vcpus is triggered by a timer,
>> registered at module initialization.
>>
>> No functionality change.
>>
>> Signed-off-by: Claudio Fontana <cfontana@suse.de>
>> ---
>>  MAINTAINERS                   |   3 +-
>>  include/hw/core/cpu.h         |  37 -------------
>>  include/qemu/main-loop.h      |   5 ++
>>  include/sysemu/cpu-throttle.h |  50 +++++++++++++++++
>>  migration/migration.c         |   1 +
>>  migration/ram.c               |   1 +
>>  softmmu/Makefile.objs         |   1 +
>>  softmmu/cpu-throttle.c        | 122 ++++++++++++++++++++++++++++++++++++++++++
>>  softmmu/cpus.c                |  95 +++-----------------------------
>>  9 files changed, 190 insertions(+), 125 deletions(-)
>>  create mode 100644 include/sysemu/cpu-throttle.h
>>  create mode 100644 softmmu/cpu-throttle.c
>>
>> diff --git a/MAINTAINERS b/MAINTAINERS
>> index 0288ffbc50..708768f120 100644
>> --- a/MAINTAINERS
>> +++ b/MAINTAINERS
>> @@ -2147,13 +2147,14 @@ F: ui/cocoa.m
>>  Main loop
>>  M: Paolo Bonzini <pbonzini@redhat.com>
>>  S: Maintained
>> -F: softmmu/cpus.c
>>  F: include/qemu/main-loop.h
>>  F: include/sysemu/runstate.h
>>  F: util/main-loop.c
>>  F: util/qemu-timer.c
>>  F: softmmu/vl.c
>>  F: softmmu/main.c
>> +F: softmmu/cpus.c
> 
> This line belong the the previous patch (#1).

right

> 
>> +F: softmmu/cpu-throttle.c
>>  F: qapi/run-state.json
> 
> Can you reorder patches #1/#2 to avoid moving cpu-throttle code twice?


I have no preference, will wait for more comments then, as you suggested elsewhere.


> 
> Otherwise this patch looks good.
> 
> [...]
> 
> 



  reply	other threads:[~2020-05-25 15:43 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-25 14:54 [RFC v3 0/4] QEMU cpus.c refactoring Claudio Fontana
2020-05-25 14:54 ` [RFC v3 1/4] softmmu: move softmmu only files from root Claudio Fontana
2020-05-25 15:12   ` Philippe Mathieu-Daudé
2020-05-25 15:37     ` Claudio Fontana
2020-05-25 17:32       ` Philippe Mathieu-Daudé
2020-05-25 14:54 ` [RFC v3 2/4] cpu-throttle: new module, extracted from cpus.c Claudio Fontana
2020-05-25 15:14   ` Philippe Mathieu-Daudé
2020-05-25 15:42     ` Claudio Fontana [this message]
2020-05-25 14:54 ` [RFC v3 3/4] cpu-timers, icount: new modules Claudio Fontana
2020-05-25 15:16   ` Philippe Mathieu-Daudé
2020-05-25 15:43     ` Claudio Fontana
2020-05-25 14:54 ` [RFC v3 4/4] cpus: extract out accel-specific code to each accel Claudio Fontana
2020-05-25 15:22   ` Philippe Mathieu-Daudé
2020-05-25 15:37     ` Claudio Fontana
2020-05-26 19:16   ` Roman Bolshakov
2020-05-27 13:42     ` Claudio Fontana
2020-05-25 22:58 ` [RFC v3 0/4] QEMU cpus.c refactoring no-reply
2020-05-26 12:57   ` Claudio Fontana

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=c1387681-fe93-d42b-c2b6-40b91c6801f1@suse.de \
    --to=cfontana@suse.de \
    --cc=alex.bennee@linaro.org \
    --cc=colin.xu@intel.com \
    --cc=ehabkost@redhat.com \
    --cc=haxm-team@intel.com \
    --cc=lvivier@redhat.com \
    --cc=mtosatti@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=peter.maydell@linaro.org \
    --cc=philmd@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=r.bolshakov@yadro.com \
    --cc=rth@twiddle.net \
    --cc=sunilmut@microsoft.com \
    --cc=thuth@redhat.com \
    --cc=wenchao.wang@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).