[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <9EEA19E7-668A-4CD0-B006-6B494D9FD242@suse.de>
Date: Thu, 6 Jan 2011 11:41:37 +0100
From: Alexander Graf <agraf@...e.de>
To: Zachary Amsden <zamsden@...hat.com>
Cc: "kvm@...r.kernel.org" <kvm@...r.kernel.org>,
Zachary Amsden <zamsden@...hat.com>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [KVM TSC trapping / migration 1/2] Add TSC trapping for SVM and VMX
Am 06.01.2011 um 11:10 schrieb Zachary Amsden <zamsden@...hat.com>:
> Reasons to trap the TSC are numerous, but we want to avoid it as much
> as possible for performance reasons.
>
> We provide two conservative modes via modules parameters and userspace
> hinting. First, the module can be loaded with "tsc_auto=1" as a module
> parameter, which turns on conservative TSC trapping only when it is
> required (when unstable TSC or faster KHZ CPU is detected).
>
> For userspace hinting, we enable trapping only if necessary. Userspace
> can hint that a VM needs a fixed frequency TSC, and also that SMP
> stability will be required. In that case, we conservatively turn on
> trapping when it is needed. In addition, users may now specify the
> desired TSC rate at which to run. If this rate differs significantly
> from the host rate, trapping will be enabled.
>
> There is also an override control to allow TSC trapping to be turned on
> or off unconditionally for testing.
>
> We indicate to pvclock users that the TSC is being trapped, to allow
> avoiding overhead and directly using RDTSCP (only for SVM). This
> optimization is not yet implemented.
When migrating, the implementation could switch from non-trapped to trapped, making it less attractive. The guest however does not get notified about this change. Same for the other way around.
Would it make sense to add a kvmclock interrupt to notify the guest of such a change?
Alex
>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists