Re: [RESEND 2][PATCH 4/4] Modify KVM to update guest time accounting.

!MAILaRCHIVE_VOTE_RePLACE
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: Laurent Vivier <Laurent.Vivier@...>
Cc: Ingo Molnar <mingo@...>, linux-kernel <linux-kernel@...>
Date: Monday, October 15, 2007 - 12:46 pm

Laurent Vivier wrote:

It's exactly the same issue as with systime and usertime.  The interrupt 
samples the program counter at various points at a fairly low frequency 
(milliseconds) while syscalls last a few dozens of microseconds.  
Probability makes it average out correctly in the end.

[Ingo, what about dyntick?  suppose you have just one process that calls 
read() from /dev/zero repeatedly.  There'd be very few (or no) 
interrupts -- what happens to accounting accuracy?]


Suppose the time to service the I/O is exactly equal to the amount 
running in guest mode.   Then the probability of the interrupt happening 
in guest mode is equal to it happening outside guest mode and you'd get 
50% guest, 50% system/user, which is what you want.



It's at least consistent... the same errors for everyone, so it averages 
out in the end.

-- 
error compiling committee.c: too many arguments to function

-
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Re: [RESEND 2][PATCH 4/4] Modify KVM to update guest , Christian Borntraeger, (Mon Oct 15, 7:19 am)
[PATCH] move kvm_guest_exit() after local_irq_enable(), Laurent Vivier, (Thu Oct 18, 9:19 am)
[PATCH] clear PF_VCPU in kvm_guest_exit(), Laurent Vivier, (Wed Oct 17, 9:08 am)
Use virtual cpu accounting if available for guest times., Christian Borntraeger, (Thu Oct 18, 8:39 am)
Re: [kvm-devel] Use virtual cpu accounting if available for ..., Hollis Blanchard, (Fri Oct 19, 12:57 pm)
Re: [PATCH] clear PF_VCPU in kvm_guest_exit(), Avi Kivity, (Wed Oct 17, 10:16 am)
Re: [PATCH] clear PF_VCPU in kvm_guest_exit(), Laurent Vivier, (Wed Oct 17, 11:09 am)
Re: [PATCH] clear PF_VCPU in kvm_guest_exit(), Christian Borntraeger, (Wed Oct 17, 9:18 am)
Re: [RESEND 2][PATCH 4/4] Modify KVM to update guest time ac..., Avi Kivity, (Mon Oct 15, 12:46 pm)
Re: [RESEND 2][PATCH 4/4] Modify KVM to update guest , Christian Borntraeger, (Mon Oct 15, 7:33 am)
Re: [RESEND 2][PATCH 4/4] Modify KVM to update guest time ac..., Christian Borntraeger, (Mon Oct 15, 10:39 am)