Re: [RFC v5 8/9] sched/deadline: base GRUB reclaiming on the inactive utilization

2017-05-09 Thread Luca Abeni
On Mon, 8 May 2017 10:06:13 +0200 Peter Zijlstra wrote: [...] > > > #define BW_SHIFT 20 > > > #define BW_UNIT (1 << BW_SHIFT) > > > > > > static inline > > > u64 grub_reclaim(u64 delta, struct rq *rq, struct sched_dl_entity > > > *dl_se) { > > > u64 u_inact = rq->dl.this_bw - rq->dl.ru

Re: [RFC v5 8/9] sched/deadline: base GRUB reclaiming on the inactive utilization

2017-05-08 Thread Peter Zijlstra
On Mon, May 08, 2017 at 09:41:08AM +0200, Luca Abeni wrote: > Hi Peter, > > sorry for the delay; anyway, I am working on fixing the patchset > according to the comments I received > > When working on one of your comments, I have a doubt: > > On Mon, 27 Mar 2017 16:26:33 +0200 > Peter Zijlstr

Re: [RFC v5 8/9] sched/deadline: base GRUB reclaiming on the inactive utilization

2017-05-08 Thread Luca Abeni
Hi Peter, sorry for the delay; anyway, I am working on fixing the patchset according to the comments I received When working on one of your comments, I have a doubt: On Mon, 27 Mar 2017 16:26:33 +0200 Peter Zijlstra wrote: [...] > > > #define BW_SHIFT 20 > #define BW_UNIT

Re: [RFC v5 8/9] sched/deadline: base GRUB reclaiming on the inactive utilization

2017-03-27 Thread luca abeni
On Mon, 27 Mar 2017 17:53:35 +0200 Peter Zijlstra wrote: > On Mon, Mar 27, 2017 at 04:56:51PM +0200, Luca Abeni wrote: > > > > > +u64 grub_reclaim(u64 delta, struct rq *rq, u64 u) > > > > { > > > > + u64 u_act; > > > > + > > > > + if (rq->dl.this_bw - rq->dl.running_bw > (1 << 20) -

Re: [RFC v5 8/9] sched/deadline: base GRUB reclaiming on the inactive utilization

2017-03-27 Thread Peter Zijlstra
On Mon, Mar 27, 2017 at 04:56:51PM +0200, Luca Abeni wrote: > > > +u64 grub_reclaim(u64 delta, struct rq *rq, u64 u) > > > { > > > + u64 u_act; > > > + > > > + if (rq->dl.this_bw - rq->dl.running_bw > (1 << 20) - u) > > > + u_act = u; > > > + else > > > + u_act = (1 << 20) - rq->d

Re: [RFC v5 8/9] sched/deadline: base GRUB reclaiming on the inactive utilization

2017-03-27 Thread Luca Abeni
On Mon, 27 Mar 2017 16:26:33 +0200 Peter Zijlstra wrote: > On Fri, Mar 24, 2017 at 04:53:01AM +0100, luca abeni wrote: > > From: Luca Abeni > > > > Instead of decreasing the runtime as "dq = -Uact dt" (eventually > > divided by the maximum utilization available for deadline tasks), > > decrease

Re: [RFC v5 8/9] sched/deadline: base GRUB reclaiming on the inactive utilization

2017-03-27 Thread Peter Zijlstra
On Fri, Mar 24, 2017 at 04:53:01AM +0100, luca abeni wrote: > From: Luca Abeni > > Instead of decreasing the runtime as "dq = -Uact dt" (eventually > divided by the maximum utilization available for deadline tasks), > decrease it as "dq = -(1 - Uinact) dt", where Uinact is the "inactive > utiliza

[RFC v5 8/9] sched/deadline: base GRUB reclaiming on the inactive utilization

2017-03-23 Thread luca abeni
From: Luca Abeni Instead of decreasing the runtime as "dq = -Uact dt" (eventually divided by the maximum utilization available for deadline tasks), decrease it as "dq = -(1 - Uinact) dt", where Uinact is the "inactive utilization". In this way, the maximum fraction of CPU time that can be reclaim