All of lore.kernel.org
 help / color / mirror / Atom feed
From: Peter Zijlstra <peterz@infradead.org>
To: Tejun Heo <tj@kernel.org>
Cc: Vikas Shivappa <vikas.shivappa@intel.com>,
	"Auld, Will" <will.auld@intel.com>,
	Matt Fleming <matt@console-pimps.org>,
	Vikas Shivappa <vikas.shivappa@linux.intel.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"Fleming, Matt" <matt.fleming@intel.com>
Subject: Re: Cache Allocation Technology Design
Date: Thu, 30 Oct 2014 14:18:45 +0100	[thread overview]
Message-ID: <20141030131845.GI3337@twins.programming.kicks-ass.net> (raw)
In-Reply-To: <20141030124333.GA29540@htj.dyndns.org>

On Thu, Oct 30, 2014 at 08:43:33AM -0400, Tejun Heo wrote:
> Hello, Peter.
> 
> On Thu, Oct 30, 2014 at 08:07:25AM +0100, Peter Zijlstra wrote:
> > If this means echo $tid > tasks, then sorry we can't do. There is a
> > limited number of hardware resources backing this thing. At some point
> > they're consumed and something must give.
> 
> And that something shouldn't be disallowing task migration across
> cgroups.  This simply doesn't work with co-mounting or unified
> hierarchy.  cpuset automatically takes on the nearest ancestor's
> configuration which has enough execution resources.  Maybe that can be
> an option for this too?

It will give very random and nondeterministic behaviour and basically
destroy the entire purpose of the controller (which are the very same
reasons I detest that 'new' behaviour in cpusets).

> One of the problems is that we generally assume that a task can run
> some point in time in a lot of places in the kernel and can't just not
> run a task indefinitely because it's in a cgroup configured certain
> way.

Refusing tasks into a previously empty cgroup creates no such problems.
Its already in a cgroup (wherever its parent was) and it can run there,
failing to move it to another does not affect things.

> > So either we fail mkdir, but that means allocating CLOS IDs for possibly
> > empty cgroups, or we allocate on demand which means failing task
> > assignment.
> 
> Can't fail mkdir or css enabling either.  Again, co-mounting and
> unified hierarchy.  Also, the behavior is just horrible to use from
> userland.

In order to fix the co-mounting and unified hierarchy I still need to
hear a proposal for that tasks vs processes thing.

Traditionally the cgroups were task based, but many controllers are
process based (simply because what they control is process wide, not per
task), and there was talk (2-3 years ago or so) about making the entire
cgroup thing per process, which obviously fails for all scheduler
related cgroups.

> > The same -- albeit for a different reason -- is true of the RT sched
> > groups, we simply cannot instantiate them such that tasks can join,
> > sysads _have_ to configure them before we can add tasks to them.
> 
> Yeah, RT is one of the main items which is problematic, more so
> because it's currently coupled with the normal sched controller and
> the default config doesn't have any RT slice. 

Simply because you cannot give a slice on creation; or if you did that
would mean failing mkdir when a new cgroup would exceed the available
time.

Also any !0 slice is wrong because it will not match the requirements of
the proposed workload, the administrator will have to set it to match
the workload.

Therefore 0.

> Do we completely block RT task w/o slice?  Is that okay?

We will not allow an RT task in, the write to the tasks file will fail.

The same will be true for deadline tasks, we'll fail entry into a cgroup
when the combined requirements of the tasks exceed the provisions of the
group.

There is just no way around that and still provide sane semantics.

  reply	other threads:[~2014-10-30 13:18 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-10-16 18:44 Cache Allocation Technology Design vikas
2014-10-20 16:18 ` Matt Fleming
2014-10-24 10:53   ` Peter Zijlstra
2014-10-28 23:22     ` Matt Fleming
2014-10-29  8:16       ` Peter Zijlstra
2014-10-29 12:48         ` Matt Fleming
2014-10-29 13:45           ` Peter Zijlstra
2014-10-29 16:32             ` Auld, Will
2014-10-29 17:28               ` Peter Zijlstra
2014-10-29 17:41                 ` Vikas Shivappa
2014-10-29 18:22                   ` Tejun Heo
2014-10-30  7:07                     ` Peter Zijlstra
2014-10-30  7:14                       ` Peter Zijlstra
2014-10-30 12:44                         ` Tejun Heo
2014-10-30 13:19                           ` Peter Zijlstra
2014-10-30 15:25                             ` Tejun Heo
2014-10-30 12:43                       ` Tejun Heo
2014-10-30 13:18                         ` Peter Zijlstra [this message]
2014-10-30 17:03                           ` Tejun Heo
2014-10-30 21:43                             ` Peter Zijlstra
2014-10-30 22:22                               ` Tejun Heo
2014-10-30 22:47                                 ` Peter Zijlstra
2014-11-06 16:27                                   ` Matt Fleming
2014-11-06 17:20                                     ` Vikas Shivappa
2014-10-31 13:07                                 ` Peter Zijlstra
2014-10-31 15:58                                   ` Tejun Heo
2014-11-04 13:13                                     ` Peter Zijlstra
2014-11-05 20:41                                       ` Tejun Heo
2014-10-30 14:14                         ` Matt Fleming
     [not found]                         ` <CAAAKZwvJOKsrj_yczDGaNLaNYo+_=HzsTLwDdcaTJqO2VMy8uA@mail.gmail.com>
2014-10-30 17:12                           ` Tejun Heo
2014-10-30 22:35                             ` Tim Hockin
2014-10-31 16:57                               ` Tejun Heo
2014-10-30 23:18                         ` Vikas Shivappa
2014-11-04 13:17                           ` Peter Zijlstra
2014-11-06 17:03                             ` Matt Fleming
2014-11-10 15:50                               ` Peter Zijlstra
2014-10-29 17:26     ` Vikas Shivappa
2014-10-29 18:16       ` Peter Zijlstra
2014-11-03 23:29 ` Vikas Shivappa

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20141030131845.GI3337@twins.programming.kicks-ass.net \
    --to=peterz@infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=matt.fleming@intel.com \
    --cc=matt@console-pimps.org \
    --cc=tj@kernel.org \
    --cc=vikas.shivappa@intel.com \
    --cc=vikas.shivappa@linux.intel.com \
    --cc=will.auld@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.