Re: [PATCH RFC 2/2] kvm: set affinity hint for assigned device msi

2012-01-15 Thread Michael S. Tsirkin
On Thu, Jan 12, 2012 at 04:09:17PM +0200, Avi Kivity wrote: On 10/11/2011 08:38 PM, Michael S. Tsirkin wrote: To forward an interrupt to a vcpu that runs on a host cpu different from the current one, we need an ipi which likely will cost us as much as delivering the interrupt directly to

Re: [PATCH RFC 2/2] kvm: set affinity hint for assigned device msi

2012-01-12 Thread Avi Kivity
On 10/11/2011 08:38 PM, Michael S. Tsirkin wrote: To forward an interrupt to a vcpu that runs on a host cpu different from the current one, we need an ipi which likely will cost us as much as delivering the interrupt directly to that cpu would. Set irq affinity hint to point there, irq

Re: [PATCH RFC 2/2] kvm: set affinity hint for assigned device msi

2012-01-11 Thread Marcelo Tosatti
On Mon, Oct 17, 2011 at 07:04:40PM +0200, Michael S. Tsirkin wrote: On Mon, Oct 17, 2011 at 02:07:41PM -0200, Marcelo Tosatti wrote: Configurations to consider, all common ones used for assigned devices? I mean, besides round robin, any other modes that have an issue? Interrupts can

Re: [PATCH RFC 2/2] kvm: set affinity hint for assigned device msi

2011-10-17 Thread Marcelo Tosatti
On Sun, Oct 16, 2011 at 03:12:23PM +0200, Michael S. Tsirkin wrote: On Thu, Oct 13, 2011 at 11:54:50AM -0300, Marcelo Tosatti wrote: On Tue, Oct 11, 2011 at 08:38:28PM +0200, Michael S. Tsirkin wrote: To forward an interrupt to a vcpu that runs on a host cpu different from the current

Re: [PATCH RFC 2/2] kvm: set affinity hint for assigned device msi

2011-10-17 Thread Marcelo Tosatti
On Sun, Oct 16, 2011 at 03:12:23PM +0200, Michael S. Tsirkin wrote: On Thu, Oct 13, 2011 at 11:54:50AM -0300, Marcelo Tosatti wrote: On Tue, Oct 11, 2011 at 08:38:28PM +0200, Michael S. Tsirkin wrote: To forward an interrupt to a vcpu that runs on a host cpu different from the current

Re: [PATCH RFC 2/2] kvm: set affinity hint for assigned device msi

2011-10-17 Thread Michael S. Tsirkin
On Mon, Oct 17, 2011 at 08:58:59AM -0200, Marcelo Tosatti wrote: On Sun, Oct 16, 2011 at 03:12:23PM +0200, Michael S. Tsirkin wrote: On Thu, Oct 13, 2011 at 11:54:50AM -0300, Marcelo Tosatti wrote: On Tue, Oct 11, 2011 at 08:38:28PM +0200, Michael S. Tsirkin wrote: To forward an

Re: [PATCH RFC 2/2] kvm: set affinity hint for assigned device msi

2011-10-17 Thread Michael S. Tsirkin
On Mon, Oct 17, 2011 at 09:09:46AM -0200, Marcelo Tosatti wrote: On Sun, Oct 16, 2011 at 03:12:23PM +0200, Michael S. Tsirkin wrote: On Thu, Oct 13, 2011 at 11:54:50AM -0300, Marcelo Tosatti wrote: On Tue, Oct 11, 2011 at 08:38:28PM +0200, Michael S. Tsirkin wrote: To forward an

Re: [PATCH RFC 2/2] kvm: set affinity hint for assigned device msi

2011-10-17 Thread Marcelo Tosatti
On Mon, Oct 17, 2011 at 03:32:15PM +0200, Michael S. Tsirkin wrote: On Mon, Oct 17, 2011 at 08:58:59AM -0200, Marcelo Tosatti wrote: On Sun, Oct 16, 2011 at 03:12:23PM +0200, Michael S. Tsirkin wrote: On Thu, Oct 13, 2011 at 11:54:50AM -0300, Marcelo Tosatti wrote: On Tue, Oct 11, 2011

Re: [PATCH RFC 2/2] kvm: set affinity hint for assigned device msi

2011-10-17 Thread Michael S. Tsirkin
On Mon, Oct 17, 2011 at 02:07:41PM -0200, Marcelo Tosatti wrote: On Mon, Oct 17, 2011 at 03:32:15PM +0200, Michael S. Tsirkin wrote: On Mon, Oct 17, 2011 at 08:58:59AM -0200, Marcelo Tosatti wrote: On Sun, Oct 16, 2011 at 03:12:23PM +0200, Michael S. Tsirkin wrote: On Thu, Oct 13, 2011

Re: [PATCH RFC 2/2] kvm: set affinity hint for assigned device msi

2011-10-17 Thread Michael S. Tsirkin
On Mon, Oct 17, 2011 at 02:07:41PM -0200, Marcelo Tosatti wrote: Configurations to consider, all common ones used for assigned devices? I mean, besides round robin, any other modes that have an issue? Interrupts can also be multicast, I think, but we probably don't care what happens

Re: [PATCH RFC 2/2] kvm: set affinity hint for assigned device msi

2011-10-16 Thread Michael S. Tsirkin
On Thu, Oct 13, 2011 at 11:54:50AM -0300, Marcelo Tosatti wrote: On Tue, Oct 11, 2011 at 08:38:28PM +0200, Michael S. Tsirkin wrote: To forward an interrupt to a vcpu that runs on a host cpu different from the current one, we need an ipi which likely will cost us as much as delivering the

Re: [PATCH RFC 2/2] kvm: set affinity hint for assigned device msi

2011-10-13 Thread Marcelo Tosatti
On Tue, Oct 11, 2011 at 08:38:28PM +0200, Michael S. Tsirkin wrote: To forward an interrupt to a vcpu that runs on a host cpu different from the current one, we need an ipi which likely will cost us as much as delivering the interrupt directly to that cpu would. Set irq affinity hint to

[PATCH RFC 2/2] kvm: set affinity hint for assigned device msi

2011-10-11 Thread Michael S. Tsirkin
To forward an interrupt to a vcpu that runs on a host cpu different from the current one, we need an ipi which likely will cost us as much as delivering the interrupt directly to that cpu would. Set irq affinity hint to point there, irq balancer can then take this into accound and balance