Re: [RFC PATCH] x86, kvm: use kvmclock to compute TSC deadline value

2016-07-08 Thread Paolo Bonzini
> > Luckily tsc_khz is really used by very little > > outside the tsc clocksource (which kvmclock replaces) and the TSC > > deadline timer. > > Two other ways to solve the problem, I don't know if you've considered: > * Constrain the set of hosts a given VM can run on based on the TSC > rate. (So

Re: [RFC PATCH] x86, kvm: use kvmclock to compute TSC deadline value

2016-07-08 Thread Paolo Bonzini
> > Luckily tsc_khz is really used by very little > > outside the tsc clocksource (which kvmclock replaces) and the TSC > > deadline timer. > > Two other ways to solve the problem, I don't know if you've considered: > * Constrain the set of hosts a given VM can run on based on the TSC > rate. (So

Re: [RFC PATCH] x86, kvm: use kvmclock to compute TSC deadline value

2016-07-06 Thread David Matlack
On Tue, Jul 5, 2016 at 10:36 AM, Paolo Bonzini wrote: > Bad things happen if a guest using the TSC deadline timer is migrated. > The guest doesn't re-calibrate the TSC after migration, and the > TSC frequency can and will change unless your processor supports TSC > scaling

Re: [RFC PATCH] x86, kvm: use kvmclock to compute TSC deadline value

2016-07-06 Thread David Matlack
On Tue, Jul 5, 2016 at 10:36 AM, Paolo Bonzini wrote: > Bad things happen if a guest using the TSC deadline timer is migrated. > The guest doesn't re-calibrate the TSC after migration, and the > TSC frequency can and will change unless your processor supports TSC > scaling (on Intel this is only

Re: [RFC PATCH] x86, kvm: use kvmclock to compute TSC deadline value

2016-07-06 Thread Paolo Bonzini
On 06/07/2016 15:01, Andy Lutomirski wrote: > On Jul 5, 2016 1:36 PM, "Paolo Bonzini" wrote: >> >> Bad things happen if a guest using the TSC deadline timer is migrated. >> The guest doesn't re-calibrate the TSC after migration, and the >> TSC frequency can and will change

Re: [RFC PATCH] x86, kvm: use kvmclock to compute TSC deadline value

2016-07-06 Thread Paolo Bonzini
On 06/07/2016 15:01, Andy Lutomirski wrote: > On Jul 5, 2016 1:36 PM, "Paolo Bonzini" wrote: >> >> Bad things happen if a guest using the TSC deadline timer is migrated. >> The guest doesn't re-calibrate the TSC after migration, and the >> TSC frequency can and will change unless your processor

Re: [RFC PATCH] x86, kvm: use kvmclock to compute TSC deadline value

2016-07-06 Thread Andy Lutomirski
On Jul 5, 2016 1:36 PM, "Paolo Bonzini" wrote: > > Bad things happen if a guest using the TSC deadline timer is migrated. > The guest doesn't re-calibrate the TSC after migration, and the > TSC frequency can and will change unless your processor supports TSC > scaling (on

Re: [RFC PATCH] x86, kvm: use kvmclock to compute TSC deadline value

2016-07-06 Thread Andy Lutomirski
On Jul 5, 2016 1:36 PM, "Paolo Bonzini" wrote: > > Bad things happen if a guest using the TSC deadline timer is migrated. > The guest doesn't re-calibrate the TSC after migration, and the > TSC frequency can and will change unless your processor supports TSC > scaling (on Intel this is only

[RFC PATCH] x86, kvm: use kvmclock to compute TSC deadline value

2016-07-05 Thread Paolo Bonzini
Bad things happen if a guest using the TSC deadline timer is migrated. The guest doesn't re-calibrate the TSC after migration, and the TSC frequency can and will change unless your processor supports TSC scaling (on Intel this is only Skylake) or your data center is perfectly homogeneous. The

[RFC PATCH] x86, kvm: use kvmclock to compute TSC deadline value

2016-07-05 Thread Paolo Bonzini
Bad things happen if a guest using the TSC deadline timer is migrated. The guest doesn't re-calibrate the TSC after migration, and the TSC frequency can and will change unless your processor supports TSC scaling (on Intel this is only Skylake) or your data center is perfectly homogeneous. The