[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20090121122952.18e4bb8c.kamezawa.hiroyu@jp.fujitsu.com>
Date: Wed, 21 Jan 2009 12:29:52 +0900
From: KAMEZAWA Hiroyuki <kamezawa.hiroyu@...fujitsu.com>
To: KOSAKI Motohiro <kosaki.motohiro@...fujitsu.com>
Cc: Greg KH <greg@...ah.com>, Paul Mundt <lethal@...ux-sh.org>,
Trilok Soni <soni.trilok@...il.com>,
Arve Hj?nnev?g <arve@...roid.com>,
Alan Cox <alan@...rguk.ukuu.org.uk>,
Pavel Machek <pavel@...e.cz>,
Brian Swetland <swetland@...gle.com>, arve@...gle.com,
San Mehat <san@...roid.com>, Robert Love <rlove@...gle.com>,
linux-kernel@...r.kernel.org,
"linux-omap@...r.kernel.org" <linux-omap@...r.kernel.org>,
Tony Lindgren <tony@...mide.com>,
ext Juha Yrj?l? <juha.yrjola@...idboot.com>,
viktor.rosendahl@...ia.com
Subject: Re: lowmemory android driver not needed?
On Wed, 21 Jan 2009 11:50:48 +0900 (JST)
KOSAKI Motohiro <kosaki.motohiro@...fujitsu.com> wrote:
> last year, I received many feedback from lkml folks and my article reader.
> (I monthly write kernel patch introduction article to japanese web
> magazine and receive some feedback periodically)
>
> I learned many people want flexibility notification.
> (per workload, per user, et al)
> eg. nokia lowmem driver have exception process defined by uid.
>
> at top of last year, I thought memcg don't provide good infrastructure.
> the first version memcg is just pretty funny joke. if its config turn on,
> memory workload performance decrease ~30% although the user don't use
> memcg at runtime. then nobody use it.
> but recently, KAMEZAWA hiroyuki (and Li zefan, Daisuke Nishimura et al)
> dramatically improvement memcg performance.
> now, memcg overhead become less than 1%.
^^^^^^^^^^^^
just depends on workload...
>
> Then, I think any memory accounting activity should use this infrastructure.
> That's my homework.
>
But, memcg requires much memory to track usage of pages, a page_cgroup structure,
40bytes per page on 64bit, 20bytes per page on 32bit.
Probably, for embeded people, this additinal memory usage is not acceptable.
Below is just a noise:
==
As my personal project, I'd like to write on-demand-fake-numa for generic archs.
Now, section size is 128MB on x86-64. I'd like to allow following ops.
# create_new_node (echo node_number > /sys/device/system/node/add_fake_node)
# offline memory (echo offline > /sys/device/system/memory/memoryXXX/state)
# attach offlined memory to new node
(echo node_number > /sys/device/system/memory/memoryXXX/attach)
# online memmory (echo online > /sys/device/system/memory/memoryXXX/state)
Then, memoryXXX (128MB of chunk of memory) is controlled under a new fake node
"node_number".
For embeded systems, you may be able to modify SECTION_SIZE smaller (8-16MB?) and
cpuset will give them enough resource isolation.
(But not so flexible as memory cgroup.)
you can use node+cpuset information to track memory usage by apps.
Note: OOM-Killer kills process within cpuset.
Thanks,
-Kame
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists