xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Julien Grall <julien.grall@arm.com>
To: Stefano Stabellini <sstabellini@kernel.org>
Cc: edgar.iglesias@xilinx.com, george.dunlap@eu.citrix.com,
	dario.faggioli@citrix.com, Punit Agrawal <punit.agrawal@arm.com>,
	xen-devel@lists.xenproject.org, nd@arm.com
Subject: Re: [PATCH] xen/arm: introduce vwfi parameter
Date: Mon, 20 Feb 2017 18:53:34 +0000	[thread overview]
Message-ID: <dc0a61ab-3dfc-89b8-42ce-a97eca30a3ec@arm.com> (raw)
In-Reply-To: <alpine.DEB.2.10.1702201043570.9566@sstabellini-ThinkPad-X260>

Hi Stefano,

On 20/02/17 18:47, Stefano Stabellini wrote:
> On Sun, 19 Feb 2017, Julien Grall wrote:
>>>> I don't think this is acceptable even to get a better interrupt latency.
>>>> Some
>>>> workload will care about interrupt latency and power.
>>>>
>>>> I think a better approach would be to check whether the scheduler has
>>>> another
>>>> vCPU to run. If not wait for an interrupt in the trap.
>>>>
>>>> This would save the context switch to the idle vCPU if we are still on the
>>>> time slice of the vCPU.
>>>
>>> From my limited understanding of how schedulers work, I think this
>>> cannot work reliably. It is the scheduler that needs to tell the
>>> arch-specific code to put a pcpu to sleep, not the other way around. I
>>> would appreciate if Dario could confirm this though.
>>
>> If my understanding is correct, your workload is 1 vCPU per pCPU. So why do
>> you need to trap WFI/WFE in this case?
>>
>> Would not it be easier to let the guest using them directly?
>
> This is a good question, I have already answered: I think it would break
> the scheduler. Dario confirmed it in his reply
> (1487382463.6732.146.camel@citrix.com).

I don't think it will break the scheduler, we are trapping WFI/WFE to 
take advantage of the quiescence of the guest. If we don't do that, the 
guest will just waste his slot.

Even if the WFI is done by the guest, you will receive the scheduler 
interrupt in Xen and that's fine. Did I miss anything?

Cheers,

-- 
Julien Grall

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel

  reply	other threads:[~2017-02-20 18:53 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1487286292-29502-1-git-send-email-sstabellini@kernel.org>
     [not found] ` <a271394a-6c76-027c-fb08-b3fe775224ba@arm.com>
2017-02-17 22:50   ` [PATCH] xen/arm: introduce vwfi parameter Stefano Stabellini
2017-02-18  1:47     ` Dario Faggioli
2017-02-19 21:27       ` Julien Grall
2017-02-20 10:43         ` George Dunlap
2017-02-20 11:15         ` Dario Faggioli
2017-02-19 21:34     ` Julien Grall
2017-02-20 11:35       ` Dario Faggioli
2017-02-20 18:43         ` Stefano Stabellini
2017-02-20 18:45           ` George Dunlap
2017-02-20 18:49             ` Stefano Stabellini
2017-02-20 18:47       ` Stefano Stabellini
2017-02-20 18:53         ` Julien Grall [this message]
2017-02-20 19:20           ` Dario Faggioli
2017-02-20 19:38             ` Julien Grall
2017-02-20 22:53               ` Dario Faggioli
2017-02-21  0:38                 ` Stefano Stabellini
2017-02-21  8:10                   ` Julien Grall
2017-02-21  9:24                     ` Dario Faggioli
2017-02-21 13:04                       ` Julien Grall
2017-02-21  7:59                 ` Julien Grall
2017-02-21  9:09                   ` Dario Faggioli
2017-02-21 12:30                     ` Julien Grall
2017-02-21 13:46                       ` George Dunlap
2017-02-21 15:07                         ` Dario Faggioli
2017-02-21 17:49                           ` Stefano Stabellini
2017-02-21 17:56                             ` Julien Grall
2017-02-21 18:30                               ` Stefano Stabellini
2017-02-21 19:20                                 ` Julien Grall
2017-02-22  4:21                                   ` Edgar E. Iglesias
2017-02-22 17:22                                     ` Stefano Stabellini
2017-02-23  9:19                                       ` Edgar E. Iglesias
2017-02-21 18:17                             ` George Dunlap
2017-02-22 16:40                               ` Dario Faggioli
2017-02-21 15:14                         ` Julien Grall
2017-02-21 16:59                           ` George Dunlap
2017-02-21 18:03                           ` Stefano Stabellini
2017-02-21 18:24                             ` Julien Grall
2017-02-21 16:51                       ` Dario Faggioli
2017-02-21 17:39                         ` Stefano Stabellini

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=dc0a61ab-3dfc-89b8-42ce-a97eca30a3ec@arm.com \
    --to=julien.grall@arm.com \
    --cc=dario.faggioli@citrix.com \
    --cc=edgar.iglesias@xilinx.com \
    --cc=george.dunlap@eu.citrix.com \
    --cc=nd@arm.com \
    --cc=punit.agrawal@arm.com \
    --cc=sstabellini@kernel.org \
    --cc=xen-devel@lists.xenproject.org \
    /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).