Re: [PATCH 3/5] uclampset: Add man page

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

 



On 01/25/21 09:26, Vincent Guittot wrote:
> On Sat, 23 Jan 2021 at 19:31, Qais Yousef <qais.yousef@xxxxxxx> wrote:
> >
> > On 01/20/21 15:46, Vincent Guittot wrote:
> > > > +.TP
> > > > +For example:
> > > > +.B uclampset \-s
> > > > +.I -m\ 512
> > > > +.I -M\ 700
> > > > +.PP
> > > > +will prevent any task from being boosted higher than 512. And all tasks in the
> > >
> > > will prevent any task from being boosted higher than 700
> >
> > 700 or 512 you mean here?
> >
> > > or
> > > will ensure  any task to be boosted higher than 512
> >
> > It is certainly not that. That's the confusion I was trying to clear up in this
> > note. The system values are _constraints_. It sets an upper bound on the
> > maximum uclamp_min/max value the system will apply.
> >
> > For example if a task::uclamp_min=1024 but the system::uclamp_min=512 512, then
> > effectively the task will only be boosted to 512. Once this restriction is left
> > by setting system::uclamp_min=1024 again, then the task will get the boost
> > value it requested.
> 
> ok, I got confused because uclamp -p PID  -min 512 - M 700 and uclamp
> -s  -min 512 - M 700 look quite similar but their behaviors are quite
> different.
> 
> I mean
> 
> uclamp -p PID -min 512 - M 700 will ensure that the task's utilization
> will be always reported in the range [512:700]
> The behavior is the same for the cgroup  with cpu.uclamp.min and cpu.uclamp.max

The cgroup behavior actually works like system. It is a constraint of your max
allowed util_min/max value. There's an exception to that where cgroup will
behave like '-p'...

I avoided commenting on cgroup behavior here. I plan to send a patch to
document util clamp in the kernel. For this tool since we don't interact with
cgroup I omitted talking about it.

I intend to send a patch documenting util clamp in the kernel. I think It's
better to discuss this details there?

> 
> whereas
> 
> uclamp -s -min 512 - M 700 will do the opposite; i.e. the min of
> task's utilization range will never be above 512
> 
> TBH I don't know how to make it clear that the behavior of -min is the
> opposite between -p and -s

Hopefully it'll become common knowledge at some point..

Thanks for having a look.

Cheers

--
Qais Yousef



[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux