lkml.org 
[lkml]   [2009]   [Jun]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] remove memory.limit v.s. memsw.limit comparison.
On Fri, 5 Jun 2009 09:34:20 +0900
Daisuke Nishimura <nishimura@mxp.nes.nec.co.jp> wrote:
> > Sorry, I don't push this patch as this is. But adding documentation about
> > "What happens when you set memory.limit == memsw.limit" will be necessary.
> >
> I agree.
>
I'd like to prepare some.

> > ...maybe give all jobs to user-land and keep the kernel as it is now
> > is a good choice.
> >
> > BTW, I'd like to avoid useless swap-out in memory.limit == memsw.limit case.
> > If someone has good idea, please :(
> >
> I think so too.
>
> From my simple thoughts, how about changing __mem_cgroup_try_charge() like:
>
> 1. initialize "noswap" as "bool noswap = !!(mem->res.limit == mem->memsw.limit)".
> 2. add check "if (mem->res.limit == mem->memsw.limit)" on charge failure to mem->res
> and set "noswap" to true if needed.
> 3. charge mem->memsw before mem->res.
>
> There would be other ideas, but I prefer 1 among these choices.
>
ok, thank you for advices.

Regards,
-Kame


>
> Thanks,
> Daisuke Nishimura.
>



\
 
 \ /
  Last update: 2009-06-05 04:25    [W:0.062 / U:0.188 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site