From mboxrd@z Thu Jan 1 00:00:00 1970 From: Anthony Liguori Subject: Re: [RFC] Paravirt timer for KVM Date: Fri, 12 Oct 2007 15:02:18 -0500 Message-ID: <470FD2CA.1000702@codemonkey.ws> References: <5d6222a80710120908s6b1f5845head84e7b7a463cd1@mail.gmail.com> <1192218507.14891.18.camel@basalt> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Cc: kvm-devel , Jeremy Fitzhardinge , Avi Kivity To: Hollis Blanchard Return-path: In-Reply-To: <1192218507.14891.18.camel@basalt> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org Errors-To: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org List-Id: kvm.vger.kernel.org Hollis Blanchard wrote: > On Fri, 2007-10-12 at 13:08 -0300, Glauber de Oliveira Costa wrote: > >> +config KVM_CLOCK >> + bool "KVM paravirtualized clock" >> + depends on PARAVIRT && GENERIC_CLOCKEVENTS >> + help >> + Turning on this option will allow you to run a paravirtualized clock >> + when running over the KVM hypervisor. Instead of relying on a PIT >> + (or probably other) emulation by the underlying device model, the host >> + provides the guest with timing infrastructure, as time of day, and >> + timer expiration. >> > > I must have missed earlier discussion on this topic, so I'm left > wondering... what's the point? What's wrong with PIT (et al) emulation? > There are three separate reasons, that I know of, to have a PV timer. 1) the PIT is periodic. a PV timer can offer a one shot timer which enables dynticks. 2) the TSC would have to be used as a clocksource. You don't know the frequency which is the first problem with using the TSC but some systems have a TSC that changes frequencies. A PV time source gives you more stable clocksource (although as in glommer's patch, when the TSC can be used, it's better to use it). 3) a PV clock can support stolen time calculation which there really isn't a concept of with emulation. Regards, Anthony Liguori ------------------------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/