kvm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* A problem about optimize the kvm_vcpu_on_spin
@ 2016-11-14  1:44 Longpeng (Mike)
  2016-11-14  8:56 ` Paolo Bonzini
  0 siblings, 1 reply; 3+ messages in thread
From: Longpeng (Mike) @ 2016-11-14  1:44 UTC (permalink / raw)
  To: Paolo Bonzini, Radim Krčmář; +Cc: Wubin (H), zhaoshenglong, kvm

Hi Paolo and Radim,

Intel sdm vol3 ch-25.1.3 (p-1074) said: The “PAUSE-loop exiting” VM-execution
control is ignored if CPL > 0.

Does this means that only guest's kernelspace spinlock could causes VMexit due
to "pause-loop exiting" ?

If so, I think the kvm_vcpu_on_spin should selects a (currently not running)vcpu
which cpl=0 to boost, because the cpl>0 vcpus are not the lock-holder. (suppose
the guest isn't RT-linux)

What about your opinion ?

-- 
Regards,
Longpeng(Mike)


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: A problem about optimize the kvm_vcpu_on_spin
  2016-11-14  1:44 A problem about optimize the kvm_vcpu_on_spin Longpeng (Mike)
@ 2016-11-14  8:56 ` Paolo Bonzini
  2016-11-14  9:30   ` Longpeng (Mike)
  0 siblings, 1 reply; 3+ messages in thread
From: Paolo Bonzini @ 2016-11-14  8:56 UTC (permalink / raw)
  To: Longpeng (Mike)
  Cc: Radim Krčmář, Wubin (H), zhaoshenglong, kvm


> Intel sdm vol3 ch-25.1.3 (p-1074) said: The “PAUSE-loop exiting” VM-execution
> control is ignored if CPL > 0.
> 
> Does this means that only guest's kernelspace spinlock could causes VMexit
> due to "pause-loop exiting" ?
> 
> If so, I think the kvm_vcpu_on_spin should selects a (currently not
> running) vcpu which cpl=0 to boost, because the cpl>0 vcpus are not
> the lock-holder. (suppose the guest isn't RT-linux)
> 
> What about your opinion ?

Yes, that's a good idea!

Paolo

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: A problem about optimize the kvm_vcpu_on_spin
  2016-11-14  8:56 ` Paolo Bonzini
@ 2016-11-14  9:30   ` Longpeng (Mike)
  0 siblings, 0 replies; 3+ messages in thread
From: Longpeng (Mike) @ 2016-11-14  9:30 UTC (permalink / raw)
  To: Paolo Bonzini; +Cc: Radim Krčmář, Wubin (H), zhaoshenglong, kvm


On 2016/11/14 16:56, Paolo Bonzini wrote:

> 
>> Intel sdm vol3 ch-25.1.3 (p-1074) said: The “PAUSE-loop exiting” VM-execution
>> control is ignored if CPL > 0.
>>
>> Does this means that only guest's kernelspace spinlock could causes VMexit
>> due to "pause-loop exiting" ?
>>
>> If so, I think the kvm_vcpu_on_spin should selects a (currently not
>> running) vcpu which cpl=0 to boost, because the cpl>0 vcpus are not
>> the lock-holder. (suppose the guest isn't RT-linux)
>>
>> What about your opinion ?
> 
> Yes, that's a good idea!
> 
> Paolo


Thanks, I will send a RFC this week.

> 
> .
> 


-- 
Regards,
Longpeng(Mike)


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2016-11-14  9:31 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-11-14  1:44 A problem about optimize the kvm_vcpu_on_spin Longpeng (Mike)
2016-11-14  8:56 ` Paolo Bonzini
2016-11-14  9:30   ` Longpeng (Mike)

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).