|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [RFC 0/6] XEN scheduling hardening
On 26.07.19 13:56, Dario Faggioli wrote: [Adding George plus others x86, ARM and core-Xen people] Hi Andrii, First of all, thanks a lot for this series! The problem you mention is a long standing one, and I'm glad we're eventually starting to properly look into it. I already have one comment: I think I can see from where this come from, but I don't think 'XEN scheduling hardening' is what we're doing in this series... I'd go for something like "xen: sched: improve idle and vcpu time accounting precision", or something like that. On Fri, 2019-07-26 at 13:37 +0300, Andrii Anisov wrote:One of the scheduling problems is a misleading CPU idle time concept. Now for the CPU idle time, it is taken an idle vcpu run time. But idle vcpu run time includes IRQ processing, softirqs processing, tasklets processing, etc. Those tasks are not actual idle and they accounting may mislead CPU freq governors who rely on the CPU idle time.Indeed! And I agree this is quite bad.The other problem is that pure hypervisor tasks execution time is charged from the guest vcpu budget.Yep, equally bad.For example, IRQ and softirq processing time are charged from the current vcpu budget, which is likely the guest vcpu. This is quite unfair and may break scheduling reliability. It is proposed to charge guest vcpus for the guest actual run time and time to serve guest's hypercalls and access to emulated iomem. All the rest is calculated as the hypervisor run time (IRQ and softirq processing, branch prediction hardening, etc.)Right. We'd break things IMO. Tasklets are sometimes used to perform async actions which can't be done in guest vcpu context. Like switching a domain to shadow mode for L1TF mitigation, or marshalling all cpus for stop_machine(). You don't want to be able to block tasklets, you want them to run as soon as possible. That's not to mean it would not be a good change, or that it is impossible... It's, rather, just to raise some awareness. :-) And here we are coming back to the idea of a "hypervisor domain" I suggested about 10 years ago and which was rejected at that time... Juergen _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxxx https://lists.xenproject.org/mailman/listinfo/xen-devel
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |