Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Xen: Devel

How to handle TLB shootdown IPI on Xen

 

 

Xen devel RSS feed   Index | Next | Previous | View Threaded


jeong.seob.ahn at gmail

Aug 11, 2013, 9:22 AM

Post #1 of 7 (17 views)
Permalink
How to handle TLB shootdown IPI on Xen

All,

Currently, I have used Xen 4.2.1 with Ubuntu HVM guests.

I am just wondering how to handle the TLB shootdown IPIs in Xen.
Specifically, the guest will send the TLB shootdown IPI to remote CPUs if
TLB synchronization between CPUs is required.

In this case, I guess the hypervisor intervention is required because it
needs to route the interrupt to virtual CPUs of corresponding guest.
However, Xen seems not to intercept the event because the number of IPIs
from Xenperf is very low. Is this right?

I checked the number of IPIs is relatively high in guest OS when using 'cat
/proc/interrupts'.
I also checked the system does not invoke the '*invalidate_interrupt*'
function located in *'arch/x86/smp.c*'.

If there is no need to intervene to deal with that, could anyone explain
that how to maintain the consistent view of TLBs in the guest hosted by Xen?
Otherwise, please let me know the handling TLB shootdown IPI code in Xen.

Thanks

Jeongseob


JBeulich at suse

Aug 12, 2013, 1:36 AM

Post #2 of 7 (11 views)
Permalink
Re: How to handle TLB shootdown IPI on Xen [In reply to]

>>> On 11.08.13 at 18:22, J Ahn <jeong.seob.ahn [at] gmail> wrote:
> I am just wondering how to handle the TLB shootdown IPIs in Xen.
> Specifically, the guest will send the TLB shootdown IPI to remote CPUs if
> TLB synchronization between CPUs is required.
>
> In this case, I guess the hypervisor intervention is required because it
> needs to route the interrupt to virtual CPUs of corresponding guest.
> However, Xen seems not to intercept the event because the number of IPIs
> from Xenperf is very low. Is this right?
>
> I checked the number of IPIs is relatively high in guest OS when using 'cat
> /proc/interrupts'.
> I also checked the system does not invoke the '*invalidate_interrupt*'
> function located in *'arch/x86/smp.c*'.
>
> If there is no need to intervene to deal with that, could anyone explain
> that how to maintain the consistent view of TLBs in the guest hosted by Xen?
> Otherwise, please let me know the handling TLB shootdown IPI code in Xen.

I'm getting the impression that you simply mix up physical IPIs (as
used by the hypervisor) and their virtualized counterparts (as used
by HVM guests).

Jan


_______________________________________________
Xen-devel mailing list
Xen-devel [at] lists
http://lists.xen.org/xen-devel


jeong.seob.ahn at gmail

Aug 12, 2013, 5:47 AM

Post #3 of 7 (10 views)
Permalink
Re: How to handle TLB shootdown IPI on Xen [In reply to]

Could you tell me the how to handle the virtualized IPI on Xen ??




2013/8/12 Jan Beulich <JBeulich [at] suse>

> >>> On 11.08.13 at 18:22, J Ahn <jeong.seob.ahn [at] gmail> wrote:
> > I am just wondering how to handle the TLB shootdown IPIs in Xen.
> > Specifically, the guest will send the TLB shootdown IPI to remote CPUs if
> > TLB synchronization between CPUs is required.
> >
> > In this case, I guess the hypervisor intervention is required because it
> > needs to route the interrupt to virtual CPUs of corresponding guest.
> > However, Xen seems not to intercept the event because the number of IPIs
> > from Xenperf is very low. Is this right?
> >
> > I checked the number of IPIs is relatively high in guest OS when using
> 'cat
> > /proc/interrupts'.
> > I also checked the system does not invoke the '*invalidate_interrupt*'
> > function located in *'arch/x86/smp.c*'.
> >
> > If there is no need to intervene to deal with that, could anyone explain
> > that how to maintain the consistent view of TLBs in the guest hosted by
> Xen?
> > Otherwise, please let me know the handling TLB shootdown IPI code in Xen.
>
> I'm getting the impression that you simply mix up physical IPIs (as
> used by the hypervisor) and their virtualized counterparts (as used
> by HVM guests).
>
> Jan
>
>


JBeulich at suse

Aug 12, 2013, 6:29 AM

Post #4 of 7 (9 views)
Permalink
Re: How to handle TLB shootdown IPI on Xen [In reply to]

>>> On 12.08.13 at 14:47, J Ahn <jeong.seob.ahn [at] gmail> wrote:

Please don't top post.

> Could you tell me the how to handle the virtualized IPI on Xen ??

The virtualized IPI gets handled by the guest OS, not by Xen.

Jan


_______________________________________________
Xen-devel mailing list
Xen-devel [at] lists
http://lists.xen.org/xen-devel


jeong.seob.ahn at gmail

Aug 12, 2013, 9:04 AM

Post #5 of 7 (9 views)
Permalink
Re: How to handle TLB shootdown IPI on Xen [In reply to]

2013/8/12 Jan Beulich <JBeulich [at] suse>

> >>> On 12.08.13 at 14:47, J Ahn <jeong.seob.ahn [at] gmail> wrote:
>
> Please don't top post.
>
> > Could you tell me the how to handle the virtualized IPI on Xen ??
>
> The virtualized IPI gets handled by the guest OS, not by Xen.
>
> Jan
>
>
Sorry, I asked you the wrong question.

I was wondering how Xen works when the guest sends the TLB shootdown IPI.
You mean that there is no need to intercept the IPI on Xen.
Is my understanding right?


JBeulich at suse

Aug 12, 2013, 9:24 AM

Post #6 of 7 (9 views)
Permalink
Re: How to handle TLB shootdown IPI on Xen [In reply to]

>>> On 12.08.13 at 18:04, J Ahn <jeong.seob.ahn [at] gmail> wrote:
> I was wondering how Xen works when the guest sends the TLB shootdown IPI.
> You mean that there is no need to intercept the IPI on Xen.
> Is my understanding right?

Xen is just involved in the delivery of the virtual interrupt, but
doesn't participate in its handling.

Jan


_______________________________________________
Xen-devel mailing list
Xen-devel [at] lists
http://lists.xen.org/xen-devel


jeong.seob.ahn at gmail

Aug 12, 2013, 9:50 AM

Post #7 of 7 (9 views)
Permalink
Re: How to handle TLB shootdown IPI on Xen [In reply to]

2013/8/13 Jan Beulich <JBeulich [at] suse>

> >>> On 12.08.13 at 18:04, J Ahn <jeong.seob.ahn [at] gmail> wrote:
> > I was wondering how Xen works when the guest sends the TLB shootdown IPI.
> > You mean that there is no need to intercept the IPI on Xen.
> > Is my understanding right?
>
> Xen is just involved in the delivery of the virtual interrupt, but
> doesn't participate in its handling.
>
> Jan
>
>
As I mentioned the first post, I also guess that the hypervisor
intervention is required to route the virtual IPI.
So, I would like to know where the delivery code on Xen has been located
because I could not find the delivery point for the virtual IPI.

Does the *vmx_do_extint()* function delivery the IPI through *
__do_IRQ_guest()* ??

Thank you for your kind advice.

Xen devel RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.