On 17/10/16 10:25, Peter Zijlstra wrote:
> On Mon, Oct 17, 2016 at 08:38:57AM +0200, luca abeni wrote:
> > > Yes, there currently is no existing schedulability analysis for
> > > multi-processor EDF with random affinities (as far as I know)
> > Correction: it looks like I was wrong, and the schedulability of
> > multi-processor EDF with arbitrary affinities has already been analysed
> > in
> > A. Gujarati, F. Cerqueira, and B. Brandenburg, “Multiprocessor
> > Real-Time Scheduling with Arbitrary Processor Affinities: From Practice
> > to Theory”, Real- Time Systems, Volume 51, Issue 4, pp. 440–483.
> > Springer Verlag, 2015
> > (see https://www.mpi-sws.org/~bbb/papers/).
> > Thanks to Giuseppe Lipari for pointing me to this paper.
> Ooh, shiny. Let me go read that.
Yeah, I should read that again (last time I remember headaches :).
> > So, having DL tasks with arbitrary affinities is not a big problem from
> > the theoretical point of view... The only issue is that the
> > utilisation-based admission test that is currently implemented in the
> > kernel does not work (and given the complexity of the analysis I think
> > it is better not to perform it in the kernel :)
> So the problem with doing admission control out of the kernel is that
> then all the guarantees and resource control the kernel should provide
> are out the window, and we're back to all the reasons why SCHED_FIFO is
> a horrible horrible scheduling policy.
I agree that we must have admission control in the kernel, but I don't
see why disabling such AC and let userspace perform more complex
calculations would make scheduler policies bogus. What we have today
(modulo fixes and possible small improvements) seems a sane and simple
default admission test to me. If userspace (and here I think of some
middleware controller type of thing more than a simple user) has
knowledge (and root privileges) and needs to perform more complex tests,
it can disable the kernel AC, but still rely on resource control
mechanisms provided by the kernel to provide guarantees (such thing is
still not achievable with FIFO).