Re: rdtsc() in kvm-unit-tests on x86

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On 07/08/2015 21:19, Jintack Lim wrote:
> Hi all,
> 
> While I was looking at rdtsc() code in kvm-unit-tests (e.g. x86/vmexit.c),
> I was getting curious that out-of-order execution on the processor
> may make rdtsc() executed not in the place we expect.
> 
> Referring to this document from intel,
> http://www.intel.com/content/www/us/en/embedded/training/ia-32-ia-64-benchmark-code-execution-paper.html
> they suggested to use rdtscp instruction and other techniques to
> serialize reading tsc register.
> 
> I wonder how the serialization is achieved when using rdtsc() in
> kvm-unit-tests code.
> Or, maybe the serialization is not necessary for some reason?

kvm-unit-tests executes the instruction thousands of times, so any error
due to lack of serialization is lost in the noise.

Paolo
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux