Thread (6 messages) 6 messages, 3 authors, 2016-07-05

Re: [RFC PATCH] swap: choose swap device according to numa node

From: Aaron Lu <hidden>
Date: 2016-05-03 09:14:31

On 04/30/2016 04:25 AM, Chen, Tim C wrote:
Wonder if choosing the swap device by numa node is the most
effective way to spread the pages among the swap devices.
The intent of this patch is not to spread the pages among the swap
devices(thus to reduce lock contention on swap device's radix tree),
it's about speed up the IOs :-)
The speedup comes from spreading the swap activities among
equal priority swap devices to reduce contention on swap devices.
For v4.5, yes. And for this patch, it also has speed ups by doing IOs
locally.
If the activities are mostly confined to 1 node, then we still could
have contention on a device.  
Indeed, but I suppose that would normally happen if people has played
with numactl themselves? Otherwise, the scheduler would probably spread
the threads evenly.

Ying suggests we use a config for people to turn this off in his reply
and I can of course add that.
An alternative may be we pick another swap device on each
pass of shrink_page_list  to try to swap pages.
This can be achieved by setting the two swap devices with equal priority
and then the two swap devices will be used round robin. I have already
used it as a comparing config:
throughput of v4.5(swap device with equal priority)

Thanks for the comments!

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help