add pagesize field to /proc/pid/numa_maps
Subsystems (3)
RFC PATCH 1/1 add pagesize field to /proc/pid/numa_maps
There were some similar attempts to add vma's pagesize to numa_maps in the past, so I've distilled the most straightforward one - adding pagesize field expressing size in kbytes to each line. Although page size can be also obtained from smaps file, adding pagesize to numa_maps makes the interface more compact and easier to use without need for traversing other files.
New numa_maps output looks like that:
2aaaaac00000 default file=/dev/hugepages/hugepagefile huge pagesize=2097152 dirty=1 N0=1 7f302441a000 default file=/usr/lib64/libc-2.17.so pagesize=4096 mapped=65 mapmax=38 N0=65
--- fs/proc/task_mmu.c | 3 +++ 1 file changed, 3 insertions(+)
fs/proc/task_mmu.c +3 -0
@@ -1498,6 +1498,9 @@ static int show_numa_map(struct seq_file *m, void *v, int is_pid)if (!md->pages) goto out; +seq_puts (m," pagesize=" ); +seq_printf (m,"%lu" ,vma_kernel_pagesize (vma)); +if (md->anon)seq_printf (m," anon=%lu" , md->anon);
Signature · 7 lines
1.9.3 -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to [email protected]. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: <a href=mailto:"[email protected]"> [email protected] </a>
Quoted 6 lines · Petr Holasek
There were some similar attempts to add vma's pagesize to
numa_mapsin the past, so I've distilled the most straightforward one - adding pagesize field expressing size in kbytes to each line. Although page size can be also obtained from smaps file, adding pagesize tonuma_mapsmakes the interface more compact and easier to use without need for traversing other files.
Quoted 6 lines
New
numa_mapsoutput looks like that:
2aaaaac00000default file=/dev/hugepages/hugepagefile huge pagesize=2097152 dirty=1 N0=17f302441a000default file=/usr/lib64/libc-2.17.so pagesize=4096 mapped=65 mapmax=38 N0=65Signed-off-by Petr Holasek <[email protected]>
I guess the existing "huge" is insufficient on platforms that support multiple hugepage sizes.
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to [email protected]. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"[email protected]"> [email protected] </a>
Quoted 10 lines · David Rientjes
Quoted 8 lines · Petr Holasek
There were some similar attempts to add vma's pagesize to
numa_mapsin the past, so I've distilled the most straightforward one - adding pagesize field expressing size in kbytes to each line. Although page size can be also obtained from smaps file, adding pagesize tonuma_mapsmakes the interface more compact and easier to use without need for traversing other files.New
numa_mapsoutput looks like that:
Quoted 7 lines
Quoted 4 lines
2aaaaac00000default file=/dev/hugepages/hugepagefile huge pagesize=2097152 dirty=1 N0=17f302441a000default file=/usr/lib64/libc-2.17.so pagesize=4096 mapped=65 mapmax=38 N0=65Signed-off-by Petr Holasek <[email protected]>I guess the existing "huge" is insufficient on platforms that support multiple hugepage sizes.
Why do you think so? pagesize= could also distinguish between multiple hugepage sizes.
Signature · 8 lines
Petr Holasek [email protected] -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to [email protected]. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: <a href=mailto:"[email protected]"> [email protected] </a>