Re: [NUMA] Display and modify the memory policy of a process through /proc/<pid>/numa_policy

From: Christoph Lameter <>
Date: 2005-07-16 08:49:33
On Sat, 16 Jul 2005, Andi Kleen wrote:

> > 1. Updating the memory policy is something that can be useful in other 
> >    settings as well so it need to be separate. The patch we are discussing
> Not for external processes except in the narrow special case
> of migrating everything. External processes shouldn' t
> know about virtual addresses of other people.

Updating the memory policy is also useful if memory on one node gets 
short and you want to redirct allocations to a node that has memory free. 

A batch scheduler may anticipate memory shortages and redirect memory 
allocations in order to avoid page migration.

> > 3. Memory policy translations better be done in user space. The batch
> >    scheduler /sysadmin knows which node has what pages so it can easily 
> >    develop page movement scheme that is optimal for the process.
> I don't think the existing policies are complex enough to make
> this useful. The mapping for page migration for all of 
> them is quite straight forward.

I'd rather have that logic in userspace rather than fix up page_migrate 
again and again and again. Automatic recalculation of memory policies is 
likely an unexpected side effect of the existing page migration code. 

Policies should only change with explicit instructions from user space and 
not as a side effect of page migration.

And curiously with the old page migration code: The only way to change the 
a memory policy is by page migration and this is automatically behind your 

To unsubscribe from this list: send the line "unsubscribe linux-ia64" in
the body of a message to
More majordomo info at
Received on Fri Jul 15 18:49:44 2005

This archive was generated by hypermail 2.1.8 : 2005-08-02 09:20:40 EST