<div dir="ltr"><div class="gmail_default" style="font-family:verdana,sans-serif">kvm-clock is a paravirtualized clock that seems to use the CPUs TSC capabilities if they exist. But it may not be perfect:</div><div class="gmail_default" style="font-family:verdana,sans-serif"><br></div><div class="gmail_default"><font face="verdana, sans-serif"><a href="https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Linux/6/html/Virtualization_Host_Configuration_and_Guest_Installation_Guide/chap-Virtualization_Host_Configuration_and_Guest_Installation_Guide-KVM_guest_timing_management.html">https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Linux/6/html/Virtualization_Host_Configuration_and_Guest_Installation_Guide/chap-Virtualization_Host_Configuration_and_Guest_Installation_Guide-KVM_guest_timing_management.html</a></font><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On 25 January 2017 at 22:29, Hans-Kristian Bakke <span dir="ltr"><<a href="mailto:hkbakke@gmail.com" target="_blank">hkbakke@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_default" style="font-family:verdana,sans-serif">Actually I think that is because it may be using the newer TSC:</div><div class="gmail_default" style="font-family:verdana,sans-serif"><div class="gmail_default"> dmesg | grep clocksource</div><div class="gmail_default">[    0.000000] clocksource: kvm-clock: mask: 0xffffffffffffffff max_cycles: 0x1cd42e4dffb, max_idle_ns: 881590591483 ns</div><div class="gmail_default">[    0.000000] clocksource: refined-jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 7645519600211568 ns</div><span class=""><div class="gmail_default">[    0.000000] clocksource: hpet: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604467 ns</div></span><div class="gmail_default">[    0.092665] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 7645041785100000 ns</div><div class="gmail_default">[    0.366429] clocksource: Switched to clocksource kvm-clock</div><div class="gmail_default">[    0.378974] clocksource: acpi_pm: mask: 0xffffff max_cycles: 0xffffff, max_idle_ns: 2085701024 ns</div><div class="gmail_default">[    1.666474] tsc: Refined TSC clocksource calibration: 3200.013 MHz</div><div class="gmail_default">[    1.666479] clocksource: tsc: mask: 0xffffffffffffffff max_cycles: 0x2e20562a1bb, max_idle_ns: 440795285529 ns</div><div><br></div></div></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><div class="gmail_quote">On 25 January 2017 at 22:26, Jonathan Morton <span dir="ltr"><<a href="mailto:chromatix99@gmail.com" target="_blank">chromatix99@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span><br>
> On 25 Jan, 2017, at 23:20, Hans-Kristian Bakke <<a href="mailto:hkbakke@gmail.com" target="_blank">hkbakke@gmail.com</a>> wrote:<br>
><br>
> ​[    0.000000] ACPI: HPET 0x00000000BFFE274F 000038 (v01 BOCHS  BXPCHPET 00000001 BXPC 00000001)<br>
> [    0.000000] ACPI: HPET id: 0x8086a201 base: 0xfed00000<br>
> [    0.000000] clocksource: hpet: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604467 ns<br>
> [    0.000000] hpet clockevent registered<br>
> [    0.362335] hpet0: at MMIO 0xfed00000, IRQs 2, 8, 0<br>
> [    0.362339] hpet0: 3 comparators, 64-bit 100.000000 MHz counter<br>
> [    0.661731] rtc_cmos 00:00: alarms up to one day, y3k, 114 bytes nvram, hpet irqs<br>
<br>
</span>Conspicuously absent here is a line saying “clocksource: Switched to clocksource hpet”.  That may be worth examining in more detail.<br>
<span class="m_8988031127245596407HOEnZb"><font color="#888888"><br>
 - Jonathan Morton<br>
<br>
</font></span></blockquote></div><br></div>
</div></div></blockquote></div><br></div>