<?xml version="1.0" encoding="UTF-8"?>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns="http://purl.org/rss/1.0/" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:syn="http://purl.org/rss/1.0/modules/syndication/" xmlns:admin="http://webns.net/mvcb/">
  <channel rdf:about="http://permalink.gmane.org/gmane.linux.kernel.mm">
    <title>gmane.linux.kernel.mm</title>
    <link>http://permalink.gmane.org/gmane.linux.kernel.mm</link>
    <description/>
    <syn:updatePeriod>hourly</syn:updatePeriod>
    <syn:updateFrequency>1</syn:updateFrequency>
    <syn:updateBase>1901-01-01T00:00+00:00</syn:updateBase>
    <items>
      <rdf:Seq>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.linux.kernel.mm/79053"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.linux.kernel.mm/79051"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.linux.kernel.mm/79049"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.linux.kernel.mm/79048"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.linux.kernel.mm/79047"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.linux.kernel.mm/79046"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.linux.kernel.mm/79045"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.linux.kernel.mm/79044"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.linux.kernel.mm/79043"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.linux.kernel.mm/79042"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.linux.kernel.mm/79041"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.linux.kernel.mm/79040"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.linux.kernel.mm/79039"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.linux.kernel.mm/79037"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.linux.kernel.mm/79034"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.linux.kernel.mm/79033"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.linux.kernel.mm/79032"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.linux.kernel.mm/79031"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.linux.kernel.mm/79030"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.linux.kernel.mm/79029"/>
      </rdf:Seq>
    </items>
    <image rdf:resource="http://gmane.org/img/gmane-25t.png"/>
    <textinput rdf:resource=""/>
  </channel>
  <image rdf:about="http://gmane.org/img/gmane-25t.png">
    <title>Gmane</title>
    <url>http://gmane.org/img/gmane-25t.png</url>
    <link>http://gmane.org</link>
  </image>
  <item rdf:about="http://permalink.gmane.org/gmane.linux.kernel.mm/79053">
    <title>[PATCH] mm/numa: Fix kernel crash caused by offline node</title>
    <link>http://permalink.gmane.org/gmane.linux.kernel.mm/79053</link>
    <description>&lt;pre&gt;I tried to boot the updated kernel (3.4.0+) on IBM power machine.
Unfortunately, I got kernel crash as follows. Then I traced it
down until I found sched/core.c::sched_init_numa tried to allocate
memory from the possible nodes. That doesn't make sense since the
possible nodes might never come in for ever.

Linux version 3.4.0+ (shangw&amp;lt; at &amp;gt;shangw) (gcc version 4.4.5 (crosstool-NG 1.13.0) ) #154 SMP Sat May 26 15:33:20 CST 2012
:
Unable to handle kernel paging request for data at address 0x00001388
Faulting instruction address: 0xc00000000017d44c
Oops: Kernel access of bad area, sig: 11 [#1]
SMP NR_CPUS=1024 NUMA PowerNV
Modules linked in:
NIP: c00000000017d44c LR: c00000000017d448 CTR: 000000002f805eb0
REGS: c0000007f22836d0 TRAP: 0300   Not tainted  (3.4.0+)
MSR: 9000000000009032 &amp;lt;SF,HV,EE,ME,IR,DR,RI&amp;gt;  CR: 28004082  XER: 00000000
SOFTE: 1
CFAR: c000000000005100
DAR: 0000000000001388, DSISR: 40000000
TASK = c0000007f21c0000[1] 'swapper/0' THREAD: c0000007f2280000 CPU: 0
GPR00: c00000000017d448 c0000007f2283950 c&lt;/pre&gt;</description>
    <dc:creator>Gavin Shan</dc:creator>
    <dc:date>2012-05-26T08:03:51</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.linux.kernel.mm/79051">
    <title>Re: [PATCH v1 1/6] timer: make __next_timer_interrupt explicit about no future event</title>
    <link>http://permalink.gmane.org/gmane.linux.kernel.mm/79051</link>
    <description>&lt;pre&gt;
The tree was never really ready for review.  I pushed the tree just for
reference to the nohz cpusets work, and so that I have something I can
refer people to when I start participating more actively in that discussion.

It didn't seem useful to post a single patch by itself without more
motivating examples behind it (i.e. without the entirety of the tree).

&lt;/pre&gt;</description>
    <dc:creator>Chris Metcalf</dc:creator>
    <dc:date>2012-05-25T20:56:16</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.linux.kernel.mm/79049">
    <title>Re: [PATCH] tmpfs not interleaving properly</title>
    <link>http://permalink.gmane.org/gmane.linux.kernel.mm/79049</link>
    <description>&lt;pre&gt;The patch attempt to spread out the node usage by starting files at nodes other
then 0.  node_offset is set to a random node when the inode is allocated.  

Using the address arg would be better.  It also makes clear that we should
still be using the index for looking up the memory policy.

The node_offset is only used when MPOL_INTERLEAVE is in effect. However
node_offset is set unconditionally.  It would be quite easy to only generate
the offset when the policy is set to interleave. 

This concern should be obviated using the address arg instead of 'altering' the
vm_pgoff.


--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo&amp;lt; at &amp;gt;kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: &amp;lt;a href=mailto:"dont&amp;lt; at &amp;gt;kvack.org"&amp;gt; email&amp;lt; at &amp;gt;kvack.org &amp;lt;/a&amp;gt;

&lt;/pre&gt;</description>
    <dc:creator>Nathan Zimmer</dc:creator>
    <dc:date>2012-05-25T20:46:27</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.linux.kernel.mm/79048">
    <title>Re: [PATCH 03/35] xen: document Xen is using an unused bit for the pagetables</title>
    <link>http://permalink.gmane.org/gmane.linux.kernel.mm/79048</link>
    <description>&lt;pre&gt;
Andrea, my previous respone had a question about this - was wondering
if you had a chance to look at that in your busy schedule and provide
some advice on how to remove the _PAGE_IOMAP altogether?

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo&amp;lt; at &amp;gt;kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: &amp;lt;a href=mailto:"dont&amp;lt; at &amp;gt;kvack.org"&amp;gt; email&amp;lt; at &amp;gt;kvack.org &amp;lt;/a&amp;gt;

&lt;/pre&gt;</description>
    <dc:creator>Konrad Rzeszutek Wilk</dc:creator>
    <dc:date>2012-05-25T20:26:56</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.linux.kernel.mm/79047">
    <title>[PATCH 14/35] autonuma: knuma_migrated per NUMA node queues</title>
    <link>http://permalink.gmane.org/gmane.linux.kernel.mm/79047</link>
    <description>&lt;pre&gt;This implements the knuma_migrated queues. The pages are added to
these queues through the NUMA hinting page faults (memory follow CPU
algorithm with false sharing evaluation) and knuma_migrated then is
waken with a certain hysteresis to migrate the memory in round robin
from all remote nodes to its local node.

The head that belongs to the local node that knuma_migrated runs on,
for now must be empty and it's not being used.

Signed-off-by: Andrea Arcangeli &amp;lt;aarcange&amp;lt; at &amp;gt;redhat.com&amp;gt;
---
 include/linux/mmzone.h |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/include/linux/mmzone.h b/include/linux/mmzone.h
index 41aa49b..8e578e6 100644
--- a/include/linux/mmzone.h
+++ b/include/linux/mmzone.h
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -666,6 +666,12 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; typedef struct pglist_data {
 struct task_struct *kswapd;
 int kswapd_max_order;
 enum zone_type classzone_idx;
+#ifdef CONFIG_AUTONUMA
+spinlock_t autonuma_lock;
+struct list_head autonuma_migrate_head[MAX_NUMNODES];
+unsigned long autonuma_nr_migrate_pages;
+wait_qu&lt;/pre&gt;</description>
    <dc:creator>Andrea Arcangeli</dc:creator>
    <dc:date>2012-05-25T17:02:18</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.linux.kernel.mm/79046">
    <title>[PATCH 28/35] autonuma: retain page last_nid information in khugepaged</title>
    <link>http://permalink.gmane.org/gmane.linux.kernel.mm/79046</link>
    <description>&lt;pre&gt;When pages are collapsed try to keep the last_nid information from one
of the original pages.

Signed-off-by: Andrea Arcangeli &amp;lt;aarcange&amp;lt; at &amp;gt;redhat.com&amp;gt;
---
 mm/huge_memory.c |   11 +++++++++++
 1 files changed, 11 insertions(+), 0 deletions(-)

diff --git a/mm/huge_memory.c b/mm/huge_memory.c
index d388517..76bdc48 100644
--- a/mm/huge_memory.c
+++ b/mm/huge_memory.c
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -1805,7 +1805,18 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; static bool __collapse_huge_page_copy(pte_t *pte, struct page *page,
 clear_user_highpage(page, address);
 add_mm_counter(vma-&amp;gt;vm_mm, MM_ANONPAGES, 1);
 } else {
+#ifdef CONFIG_AUTONUMA
+int autonuma_last_nid;
+#endif
 src_page = pte_page(pteval);
+#ifdef CONFIG_AUTONUMA
+/* pick the last one, better than nothing */
+autonuma_last_nid =
+ACCESS_ONCE(src_page-&amp;gt;autonuma_last_nid);
+if (autonuma_last_nid &amp;gt;= 0)
+ACCESS_ONCE(page-&amp;gt;autonuma_last_nid) =
+autonuma_last_nid;
+#endif
 copy_user_highpage(page, src_page, address, vma);
 VM_BUG_ON(page_mapcount(src_page) != 1);
 VM_BUG_ON(page_&lt;/pre&gt;</description>
    <dc:creator>Andrea Arcangeli</dc:creator>
    <dc:date>2012-05-25T17:02:32</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.linux.kernel.mm/79045">
    <title>[PATCH 00/35] AutoNUMA alpha14</title>
    <link>http://permalink.gmane.org/gmane.linux.kernel.mm/79045</link>
    <description>&lt;pre&gt;Hello everyone,

It's time for a new autonuma-alpha14 milestone.

Removed the [RFC] from Subject because 1) this is a release I'm quite
happy with (from the implementation side it allows the same kernel
image to boot optimally on NUMA and not-NUMA hardware and it avoids
altering the scheduler runtime most of the time) and 2) because of the
great benchmark results we got so far, showing this design so far has
been proved to perform best.

I believe (realistically speaking) nobody is going to change
applications to specify which thread is using which memory (for
threaded apps) with the only exception of QEMU and a few others.

For not threaded apps that fits in a NUMA node, there's no way a blind
home node can perform nearly as good as AutoNUMA: AutoNUMA monitor the
whole status of the memory of the running processes and it optimizes
the memory placement and CPU placement dynamically
accordingly. There's a small memory and CPU cost in collecting so much
information to be able to make smart decisions, but the b&lt;/pre&gt;</description>
    <dc:creator>Andrea Arcangeli</dc:creator>
    <dc:date>2012-05-25T17:02:04</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.linux.kernel.mm/79044">
    <title>[PATCH 32/35] autonuma: link mm/autonuma.o and kernel/sched/numa.o</title>
    <link>http://permalink.gmane.org/gmane.linux.kernel.mm/79044</link>
    <description>&lt;pre&gt;Link the AutoNUMA core and scheduler object files in the kernel if
CONFIG_AUTONUMA=y.

Signed-off-by: Andrea Arcangeli &amp;lt;aarcange&amp;lt; at &amp;gt;redhat.com&amp;gt;
---
 kernel/sched/Makefile |    1 +
 mm/Makefile           |    1 +
 2 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/kernel/sched/Makefile b/kernel/sched/Makefile
index 173ea52..783a840 100644
--- a/kernel/sched/Makefile
+++ b/kernel/sched/Makefile
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -16,3 +16,4 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; obj-$(CONFIG_SMP) += cpupri.o
 obj-$(CONFIG_SCHED_AUTOGROUP) += auto_group.o
 obj-$(CONFIG_SCHEDSTATS) += stats.o
 obj-$(CONFIG_SCHED_DEBUG) += debug.o
+obj-$(CONFIG_AUTONUMA) += numa.o
diff --git a/mm/Makefile b/mm/Makefile
index 50ec00e..67c77bd 100644
--- a/mm/Makefile
+++ b/mm/Makefile
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -29,6 +29,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; obj-$(CONFIG_SWAP)+= page_io.o swap_state.o swapfile.o thrash.o
 obj-$(CONFIG_HAS_DMA)+= dmapool.o
 obj-$(CONFIG_HUGETLBFS)+= hugetlb.o
 obj-$(CONFIG_NUMA) += mempolicy.o
+obj-$(CONFIG_AUTONUMA) += autonuma.o
 obj-$(CONFIG_SPARSEMEM)+= sparse.o
 obj-$(CONFIG_SPARSEMEM_VMEMMAP) += spar&lt;/pre&gt;</description>
    <dc:creator>Andrea Arcangeli</dc:creator>
    <dc:date>2012-05-25T17:02:36</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.linux.kernel.mm/79043">
    <title>[PATCH 08/35] autonuma: introduce kthread_bind_node()</title>
    <link>http://permalink.gmane.org/gmane.linux.kernel.mm/79043</link>
    <description>&lt;pre&gt;This function makes it easy to bind the per-node knuma_migrated
threads to their respective NUMA nodes. Those threads take memory from
the other nodes (in round robin with a incoming queue for each remote
node) and they move that memory to their local node.

Signed-off-by: Andrea Arcangeli &amp;lt;aarcange&amp;lt; at &amp;gt;redhat.com&amp;gt;
---
 include/linux/kthread.h |    1 +
 kernel/kthread.c        |   23 +++++++++++++++++++++++
 2 files changed, 24 insertions(+), 0 deletions(-)

diff --git a/include/linux/kthread.h b/include/linux/kthread.h
index 0714b24..e733f97 100644
--- a/include/linux/kthread.h
+++ b/include/linux/kthread.h
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -33,6 +33,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; struct task_struct *kthread_create_on_node(int (*threadfn)(void *data),
 })
 
 void kthread_bind(struct task_struct *k, unsigned int cpu);
+void kthread_bind_node(struct task_struct *p, int nid);
 int kthread_stop(struct task_struct *k);
 int kthread_should_stop(void);
 bool kthread_freezable_should_stop(bool *was_frozen);
diff --git a/kernel/kthread.c b/kernel/kthread.c
index 3d3de63..48b3&lt;/pre&gt;</description>
    <dc:creator>Andrea Arcangeli</dc:creator>
    <dc:date>2012-05-25T17:02:12</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.linux.kernel.mm/79042">
    <title>[PATCH 30/35] autonuma: reset autonuma page data when pages are freed</title>
    <link>http://permalink.gmane.org/gmane.linux.kernel.mm/79042</link>
    <description>&lt;pre&gt;When pages are freed abort any pending migration. If knuma_migrated
arrives first it will notice because get_page_unless_zero would fail.

Signed-off-by: Andrea Arcangeli &amp;lt;aarcange&amp;lt; at &amp;gt;redhat.com&amp;gt;
---
 mm/page_alloc.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/mm/page_alloc.c b/mm/page_alloc.c
index 3d1ee70..1d3163f 100644
--- a/mm/page_alloc.c
+++ b/mm/page_alloc.c
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -614,6 +614,10 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; static inline int free_pages_check(struct page *page)
 bad_page(page);
 return 1;
 }
+autonuma_migrate_page_remove(page);
+#ifdef CONFIG_AUTONUMA
+ACCESS_ONCE(page-&amp;gt;autonuma_last_nid) = -1;
+#endif
 if (page-&amp;gt;flags &amp;amp; PAGE_FLAGS_CHECK_AT_PREP)
 page-&amp;gt;flags &amp;amp;= ~PAGE_FLAGS_CHECK_AT_PREP;
 return 0;

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo&amp;lt; at &amp;gt;kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: &amp;lt;a href=mailto:"dont&amp;lt; at &amp;gt;kvack.org"&amp;gt; email&amp;lt; at &amp;gt;kvack.o&lt;/pre&gt;</description>
    <dc:creator>Andrea Arcangeli</dc:creator>
    <dc:date>2012-05-25T17:02:34</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.linux.kernel.mm/79041">
    <title>[PATCH 34/35] autonuma: boost khugepaged scanning rate</title>
    <link>http://permalink.gmane.org/gmane.linux.kernel.mm/79041</link>
    <description>&lt;pre&gt;Until THP native migration is implemented it's safer to boost
khugepaged scanning rate because all memory migration are splitting
the hugepages. So the regular rate of scanning becomes too low when
lots of memory is migrated.

Signed-off-by: Andrea Arcangeli &amp;lt;aarcange&amp;lt; at &amp;gt;redhat.com&amp;gt;
---
 mm/huge_memory.c |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)

diff --git a/mm/huge_memory.c b/mm/huge_memory.c
index 017c0a3..b919c0c 100644
--- a/mm/huge_memory.c
+++ b/mm/huge_memory.c
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -573,6 +573,14 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; static int __init hugepage_init(void)
 
 set_recommended_min_free_kbytes();
 
+#ifdef CONFIG_AUTONUMA
+/* Hack, remove after THP native migration */
+if (num_possible_nodes() &amp;gt; 1) {
+khugepaged_scan_sleep_millisecs = 100;
+khugepaged_alloc_sleep_millisecs = 10000;
+}
+#endif
+
 return 0;
 out:
 hugepage_exit_sysfs(hugepage_kobj);

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo&amp;lt; at &amp;gt;kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight &lt;/pre&gt;</description>
    <dc:creator>Andrea Arcangeli</dc:creator>
    <dc:date>2012-05-25T17:02:38</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.linux.kernel.mm/79040">
    <title>[PATCH 05/35] autonuma: x86 pte_numa() and pmd_numa()</title>
    <link>http://permalink.gmane.org/gmane.linux.kernel.mm/79040</link>
    <description>&lt;pre&gt;Implement pte_numa and pmd_numa and related methods on x86 arch.

We must atomically set the numa bit and clear the present bit to
define a pte_numa or pmd_numa.

Whenever a pte or pmd is set as pte_numa or pmd_numa the first time a
thread will touch that virtual address, a NUMA hinting page fault will
trigger. The NUMA hinting page fault will simply clear the NUMA bit
and set the present bit again to resolve the page fault.

NUMA hinting page faults are used:

1) to fill in the per-thread NUMA statistic stored for each thread in
   a current-&amp;gt;sched_autonuma data structure

2) to track the per-node last_nid information in the page structure to
   detect false sharing

3) to queue the page mapped by the pte_numa or pmd_numa for async
   migration if there have been enough NUMA hinting page faults on the
   page coming from remote CPUs

NUMA hinting page faults don't do anything except collecting
information and possibly adding pages to migrate queues. They're
extremely quick and absolutely non blocking. They &lt;/pre&gt;</description>
    <dc:creator>Andrea Arcangeli</dc:creator>
    <dc:date>2012-05-25T17:02:09</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.linux.kernel.mm/79039">
    <title>[PATCH 31/35] autonuma: initialize page structure fields</title>
    <link>http://permalink.gmane.org/gmane.linux.kernel.mm/79039</link>
    <description>&lt;pre&gt;Initialize the AutoNUMA page structure fields at boot.

Signed-off-by: Andrea Arcangeli &amp;lt;aarcange&amp;lt; at &amp;gt;redhat.com&amp;gt;
---
 mm/page_alloc.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/mm/page_alloc.c b/mm/page_alloc.c
index 1d3163f..3c354d4 100644
--- a/mm/page_alloc.c
+++ b/mm/page_alloc.c
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -3673,6 +3673,10 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; void __meminit memmap_init_zone(unsigned long size, int nid, unsigned long zone,
 set_pageblock_migratetype(page, MIGRATE_MOVABLE);
 
 INIT_LIST_HEAD(&amp;amp;page-&amp;gt;lru);
+#ifdef CONFIG_AUTONUMA
+page-&amp;gt;autonuma_last_nid = -1;
+page-&amp;gt;autonuma_migrate_nid = -1;
+#endif
 #ifdef WANT_PAGE_VIRTUAL
 /* The shift won't overflow because ZONE_NORMAL is below 4G. */
 if (!is_highmem_idx(zone))

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo&amp;lt; at &amp;gt;kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: &amp;lt;a href=mailto:"dont&amp;lt; at &amp;gt;kvack.org"&amp;gt; email&amp;lt; at &amp;gt;kvac&lt;/pre&gt;</description>
    <dc:creator>Andrea Arcangeli</dc:creator>
    <dc:date>2012-05-25T17:02:35</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.linux.kernel.mm/79037">
    <title>[PATCH 01/35] mm: add unlikely to the mm allocation failure check</title>
    <link>http://permalink.gmane.org/gmane.linux.kernel.mm/79037</link>
    <description>&lt;pre&gt;Very minor optimization to hint gcc.

Signed-off-by: Andrea Arcangeli &amp;lt;aarcange&amp;lt; at &amp;gt;redhat.com&amp;gt;
---
 kernel/fork.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/kernel/fork.c b/kernel/fork.c
index 47b4e4f..98db8b0 100644
--- a/kernel/fork.c
+++ b/kernel/fork.c
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -571,7 +571,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; struct mm_struct *mm_alloc(void)
 struct mm_struct *mm;
 
 mm = allocate_mm();
-if (!mm)
+if (unlikely(!mm))
 return NULL;
 
 memset(mm, 0, sizeof(*mm));

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo&amp;lt; at &amp;gt;kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: &amp;lt;a href=mailto:"dont&amp;lt; at &amp;gt;kvack.org"&amp;gt; email&amp;lt; at &amp;gt;kvack.org &amp;lt;/a&amp;gt;

&lt;/pre&gt;</description>
    <dc:creator>Andrea Arcangeli</dc:creator>
    <dc:date>2012-05-25T17:02:05</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.linux.kernel.mm/79034">
    <title>[PATCH 23/35] autonuma: core</title>
    <link>http://permalink.gmane.org/gmane.linux.kernel.mm/79034</link>
    <description>&lt;pre&gt;This implements knuma_scand, the numa_hinting faults started by
knuma_scand, the knuma_migrated that migrates the memory queued by the
NUMA hinting faults, the statistics gathering code that is done by
knuma_scand for the mm_autonuma and by the numa hinting page faults
for the sched_autonuma, and most of the rest of the AutoNUMA core
logics like the false sharing detection, sysfs and initialization
routines.

The AutoNUMA algorithm when knuma_scand is not running is a full
bypass and it must not alter the runtime of memory management and
scheduler.

The whole AutoNUMA logic is a chain reaction as result of the actions
of the knuma_scand. The various parts of the code can be described
like different gears (gears as in glxgears).

knuma_scand is the first gear and it collects the mm_autonuma per-process
statistics and at the same time it sets the pte/pmd it scans as
pte_numa and pmd_numa.

The second gear are the numa hinting page faults. These are triggered
by the pte_numa/pmd_numa pmd/ptes. They collect the &lt;/pre&gt;</description>
    <dc:creator>Andrea Arcangeli</dc:creator>
    <dc:date>2012-05-25T17:02:27</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.linux.kernel.mm/79033">
    <title>[PATCH 11/35] autonuma: core autonuma.h header</title>
    <link>http://permalink.gmane.org/gmane.linux.kernel.mm/79033</link>
    <description>&lt;pre&gt;This is the generic autonuma.h header that defines the generic
AutoNUMA specific functions like autonuma_setup_new_exec,
autonuma_split_huge_page, numa_hinting_fault, etc...

As usual functions like numa_hinting_fault that only matter for builds
with CONFIG_AUTONUMA=y are defined unconditionally, but they are only
linked into the kernel if CONFIG_AUTONUMA=n. Their call sites are
optimized away at build time (or kernel won't link).

Signed-off-by: Andrea Arcangeli &amp;lt;aarcange&amp;lt; at &amp;gt;redhat.com&amp;gt;
---
 include/linux/autonuma.h |   41 +++++++++++++++++++++++++++++++++++++++++
 1 files changed, 41 insertions(+), 0 deletions(-)
 create mode 100644 include/linux/autonuma.h

diff --git a/include/linux/autonuma.h b/include/linux/autonuma.h
new file mode 100644
index 0000000..a963dcb
--- /dev/null
+++ b/include/linux/autonuma.h
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -0,0 +1,41 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt;
+#ifndef _LINUX_AUTONUMA_H
+#define _LINUX_AUTONUMA_H
+
+#ifdef CONFIG_AUTONUMA
+
+#include &amp;lt;linux/autonuma_flags.h&amp;gt;
+
+extern void autonuma_enter(struct mm_struct *mm);
+extern void aut&lt;/pre&gt;</description>
    <dc:creator>Andrea Arcangeli</dc:creator>
    <dc:date>2012-05-25T17:02:15</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.linux.kernel.mm/79032">
    <title>[PATCH 21/35] autonuma: teach CFS about autonuma affinity</title>
    <link>http://permalink.gmane.org/gmane.linux.kernel.mm/79032</link>
    <description>&lt;pre&gt;The CFS scheduler is still in charge of all scheduling
decisions. AutoNUMA balancing at times will override those. But
generally we'll just relay on the CFS scheduler to keep doing its
thing, but while preferring the autonuma affine nodes when deciding
to move a process to a different runqueue or when waking it up.

For example the idle balancing, will look into the runqueues of the
busy CPUs, but it'll search first for a task that wants to run into
the idle CPU in AutoNUMA terms (task_autonuma_cpu() being true).

Most of this is encoded in the can_migrate_task becoming AutoNUMA
aware and running two passes for each balancing pass, the first NUMA
aware, and the second one relaxed.

The idle/newidle balancing is always allowed to fallback into
non-affine AutoNUMA tasks. The load_balancing (which is more a
fariness than a performance issue) is instead only able to cross over
the AutoNUMA affinity if the flag controlled by
/sys/kernel/mm/autonuma/scheduler/load_balance_strict is not set (it
is set by default).
&lt;/pre&gt;</description>
    <dc:creator>Andrea Arcangeli</dc:creator>
    <dc:date>2012-05-25T17:02:25</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.linux.kernel.mm/79031">
    <title>[PATCH 15/35] autonuma: init knuma_migrated queues</title>
    <link>http://permalink.gmane.org/gmane.linux.kernel.mm/79031</link>
    <description>&lt;pre&gt;Initialize the knuma_migrated queues at boot time.

Signed-off-by: Andrea Arcangeli &amp;lt;aarcange&amp;lt; at &amp;gt;redhat.com&amp;gt;
---
 mm/page_alloc.c |   11 +++++++++++
 1 files changed, 11 insertions(+), 0 deletions(-)

diff --git a/mm/page_alloc.c b/mm/page_alloc.c
index 3d69735..3d1ee70 100644
--- a/mm/page_alloc.c
+++ b/mm/page_alloc.c
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -58,6 +58,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt;
 #include &amp;lt;linux/memcontrol.h&amp;gt;
 #include &amp;lt;linux/prefetch.h&amp;gt;
 #include &amp;lt;linux/page-debug-flags.h&amp;gt;
+#include &amp;lt;linux/autonuma.h&amp;gt;
 
 #include &amp;lt;asm/tlbflush.h&amp;gt;
 #include &amp;lt;asm/div64.h&amp;gt;
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -4295,8 +4296,18 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; static void __paginginit free_area_init_core(struct pglist_data *pgdat,
 int nid = pgdat-&amp;gt;node_id;
 unsigned long zone_start_pfn = pgdat-&amp;gt;node_start_pfn;
 int ret;
+#ifdef CONFIG_AUTONUMA
+int node_iter;
+#endif
 
 pgdat_resize_init(pgdat);
+#ifdef CONFIG_AUTONUMA
+spin_lock_init(&amp;amp;pgdat-&amp;gt;autonuma_lock);
+init_waitqueue_head(&amp;amp;pgdat-&amp;gt;autonuma_knuma_migrated_wait);
+pgdat-&amp;gt;autonuma_nr_migrate_pages = 0;
+for_each_node(node_iter)
+INIT_LIST_HEAD(&amp;amp;pgdat-&amp;gt;autonuma_migrate_he&lt;/pre&gt;</description>
    <dc:creator>Andrea Arcangeli</dc:creator>
    <dc:date>2012-05-25T17:02:19</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.linux.kernel.mm/79030">
    <title>[PATCH 26/35] autonuma: call autonuma_split_huge_page()</title>
    <link>http://permalink.gmane.org/gmane.linux.kernel.mm/79030</link>
    <description>&lt;pre&gt;This is needed to make sure the tail pages are also queued into the
migration queues of knuma_migrated across a transparent hugepage
split.

Signed-off-by: Andrea Arcangeli &amp;lt;aarcange&amp;lt; at &amp;gt;redhat.com&amp;gt;
---
 mm/huge_memory.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/mm/huge_memory.c b/mm/huge_memory.c
index 383ae4d..b1c047b 100644
--- a/mm/huge_memory.c
+++ b/mm/huge_memory.c
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -17,6 +17,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt;
 #include &amp;lt;linux/khugepaged.h&amp;gt;
 #include &amp;lt;linux/freezer.h&amp;gt;
 #include &amp;lt;linux/mman.h&amp;gt;
+#include &amp;lt;linux/autonuma.h&amp;gt;
 #include &amp;lt;asm/tlb.h&amp;gt;
 #include &amp;lt;asm/pgalloc.h&amp;gt;
 #include "internal.h"
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -1307,6 +1308,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; static void __split_huge_page_refcount(struct page *page)
 
 
 lru_add_page_tail(zone, page, page_tail);
+autonuma_migrate_split_huge_page(page, page_tail);
 }
 atomic_sub(tail_count, &amp;amp;page-&amp;gt;_count);
 BUG_ON(__page_count(page) &amp;lt;= 0);

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo&amp;lt; at &amp;gt;kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org&lt;/pre&gt;</description>
    <dc:creator>Andrea Arcangeli</dc:creator>
    <dc:date>2012-05-25T17:02:30</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.linux.kernel.mm/79029">
    <title>[PATCH 27/35] autonuma: make khugepaged pte_numa aware</title>
    <link>http://permalink.gmane.org/gmane.linux.kernel.mm/79029</link>
    <description>&lt;pre&gt;If any of the ptes that khugepaged is collapsing was a pte_numa, the
resulting trans huge pmd will be a pmd_numa too.

Signed-off-by: Andrea Arcangeli &amp;lt;aarcange&amp;lt; at &amp;gt;redhat.com&amp;gt;
---
 mm/huge_memory.c |   13 +++++++++++--
 1 files changed, 11 insertions(+), 2 deletions(-)

diff --git a/mm/huge_memory.c b/mm/huge_memory.c
index b1c047b..d388517 100644
--- a/mm/huge_memory.c
+++ b/mm/huge_memory.c
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -1790,12 +1790,13 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; out:
 return isolated;
 }
 
-static void __collapse_huge_page_copy(pte_t *pte, struct page *page,
+static bool __collapse_huge_page_copy(pte_t *pte, struct page *page,
       struct vm_area_struct *vma,
       unsigned long address,
       spinlock_t *ptl)
 {
 pte_t *_pte;
+bool mknuma = false;
 for (_pte = pte; _pte &amp;lt; pte+HPAGE_PMD_NR; _pte++) {
 pte_t pteval = *_pte;
 struct page *src_page;
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -1823,11 +1824,15 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; static void __collapse_huge_page_copy(pte_t *pte, struct page *page,
 page_remove_rmap(src_page);
 spin_unlock(ptl);
 free_page_and_swap_cache(src_page);
+
+&lt;/pre&gt;</description>
    <dc:creator>Andrea Arcangeli</dc:creator>
    <dc:date>2012-05-25T17:02:31</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.linux.kernel.mm/79028">
    <title>[PATCH 17/35] autonuma: call autonuma_setup_new_exec()</title>
    <link>http://permalink.gmane.org/gmane.linux.kernel.mm/79028</link>
    <description>&lt;pre&gt;This resets all per-thread and per-process statistics across exec
syscalls or after kernel threads detached from the mm. The past
statistical NUMA information is unlikely to be relevant for the future
in these cases.

Signed-off-by: Andrea Arcangeli &amp;lt;aarcange&amp;lt; at &amp;gt;redhat.com&amp;gt;
---
 fs/exec.c        |    3 +++
 mm/mmu_context.c |    2 ++
 2 files changed, 5 insertions(+), 0 deletions(-)

diff --git a/fs/exec.c b/fs/exec.c
index 52c9e2f..17330ba 100644
--- a/fs/exec.c
+++ b/fs/exec.c
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -55,6 +55,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt;
 #include &amp;lt;linux/pipe_fs_i.h&amp;gt;
 #include &amp;lt;linux/oom.h&amp;gt;
 #include &amp;lt;linux/compat.h&amp;gt;
+#include &amp;lt;linux/autonuma.h&amp;gt;
 
 #include &amp;lt;asm/uaccess.h&amp;gt;
 #include &amp;lt;asm/mmu_context.h&amp;gt;
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -1176,6 +1177,8 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; void setup_new_exec(struct linux_binprm * bprm)
 
 flush_signal_handlers(current, 0);
 flush_old_files(current-&amp;gt;files);
+
+autonuma_setup_new_exec(current);
 }
 EXPORT_SYMBOL(setup_new_exec);
 
diff --git a/mm/mmu_context.c b/mm/mmu_context.c
index 3dcfaf4..40f0f13 100644
--- a/mm/mmu_context.c
+++ b/mm/mmu_context.c
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -7,6 +&lt;/pre&gt;</description>
    <dc:creator>Andrea Arcangeli</dc:creator>
    <dc:date>2012-05-25T17:02:21</dc:date>
  </item>
  <textinput rdf:about="http://search.gmane.org/?group=$group=gmane.linux.kernel.mm">
    <title>Search Engine</title>
    <description>Search the mailing list at Gmane</description>
    <name>query</name>
    <link>http://search.gmane.org/?group=$group=gmane.linux.kernel.mm</link>
  </textinput>
</rdf:RDF>

