Re: [v2 PATCH 7/9] mm: vmscan: check if the demote target node is contended or not

2019-04-15 Thread Yang Shi
On 4/15/19 3:13 PM, Dave Hansen wrote: On 4/15/19 3:06 PM, Yang Shi wrote: This seems like an actively bad idea to me. Why do we need an *active* note to say the node is contended?  Why isn't just getting a failure back from migrate_pages() enough?  Have you observed this in practice? The f

Re: [v2 PATCH 7/9] mm: vmscan: check if the demote target node is contended or not

2019-04-15 Thread Dave Hansen
On 4/15/19 3:06 PM, Yang Shi wrote: >>> >> This seems like an actively bad idea to me. >> >> Why do we need an *active* note to say the node is contended?  Why isn't >> just getting a failure back from migrate_pages() enough?  Have you >> observed this in practice? > > The flag will be used to che

Re: [v2 PATCH 7/9] mm: vmscan: check if the demote target node is contended or not

2019-04-15 Thread Yang Shi
On 4/11/19 9:06 AM, Dave Hansen wrote: On 4/10/19 8:56 PM, Yang Shi wrote: When demoting to PMEM node, the target node may have memory pressure, then the memory pressure may cause migrate_pages() fail. If the failure is caused by memory pressure (i.e. returning -ENOMEM), tag the node with PG

Re: [v2 PATCH 7/9] mm: vmscan: check if the demote target node is contended or not

2019-04-11 Thread Dave Hansen
On 4/10/19 8:56 PM, Yang Shi wrote: > When demoting to PMEM node, the target node may have memory pressure, > then the memory pressure may cause migrate_pages() fail. > > If the failure is caused by memory pressure (i.e. returning -ENOMEM), > tag the node with PGDAT_CONTENDED. The tag would be cl

[v2 PATCH 7/9] mm: vmscan: check if the demote target node is contended or not

2019-04-10 Thread Yang Shi
When demoting to PMEM node, the target node may have memory pressure, then the memory pressure may cause migrate_pages() fail. If the failure is caused by memory pressure (i.e. returning -ENOMEM), tag the node with PGDAT_CONTENDED. The tag would be cleared once the target node is balanced again.