Re: [kvm-unit-tests PATCH v3 00/10] arm/arm64: Add IPI/LPI/vtimer latency test

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

 



On 2020-08-17 02:46, Jingyi Wang wrote:
On 8/11/2020 3:49 PM, Marc Zyngier wrote:
On 2020-08-11 02:48, Jingyi Wang wrote:

[...]

As I mentioned before, we want to add vLPI direct injection test
in KUT, meanwhile measure the latency of hardware vLPI injection.

Sure, vLPI is triggered by hardware. Since kernel supports sending
ITS INT command in guest to trigger vLPI, I wonder if it is possible

So can the host.

to add an extra interface to make a vLPI hardware-offload(just as
kvm_vgic_v4_set_forwarding() does). If so, vgic_its_trigger_msi()
can inject vLPI directly instead of using LR.

The interface exists, it is in debugfs. But it mandates that the
device exists. And no, I am not willing to add an extra KVM userspace
API for this.

The whole concept of injecting an INT to measure the performance
of GICv4 is slightly bonkers, actually. Most of the cost is paid
on the injection path (queuing a pair of command, waiting until
the ITS wakes up and generate the signal...).

What you really want to measure is the time from generation of
the LPI by a device until the guest acknowledges the interrupt
to the device itself. and this can only be implemented in the
device.

         M.

OK understood. I just thought measuring the latency of the path
kvm->guest can be useful.

That's the problem. There is no way you can implement this, because
you cannot distinguish injection latency from the delivery latency.
And frankly, it doesn't matter, because the hypervisor is not on
that path at all (if it is slow, that's because the HW is slow, and
you can't change anything in KVM to make it better).

On the other hand, measuring the latency of a guest being scheduled
back in when blocked on WFI would be much more relevant, as this is
exactly what would happen on delivery of a doorbell.

        M.
--
Jazz is not dead. It just smells funny...



[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