linux/Documentation/vm
Jiajian Ye ebbeae3638 tools/vm/page_owner_sort.c: support sorting blocks by multiple keys
When viewing page owner information, we may want to sort blocks of
information by multiple keys, since one single key does not uniquely
identify a block. Therefore, following adjustments are made:

1. Add a new --sort option to support sorting blocks of information by
multiple keys.

	./page_owner_sort <input> <output> --sort=<order>
	./page_owner_sort <input> <output> --sort <order>

<order> is a single argument in the form of a comma-separated list,
which offers a way to specify sorting order.

Sorting syntax is [+|-]key[,[+|-]key[,...]]. The ascending or descending
order can be specified by adding the + (ascending, default) or - (descend
-ing) prefix to the key:

	./page_owner_sort <input> <output> [option] --sort -key1,+key2,key3...

For example, to sort the blocks first by task command name in lexicographic
order and then by pid in ascending numerical order, use the following:

	./page_owner_sort <input> <output> --sort=name,+pid

To sort the blocks first by pid in ascending order and then by timestamp
of the page when it is allocated in descending order, use the following:

	./page_owner_sort <input> <output> --sort=pid,-alloc_ts

2. Add explanations of a newly added --sort option in the function usage()
and the document(Documentation/vm/page_owner.rst).

This work is coauthored by
	Yixuan Cao
	Shenghong Han
	Yinan Zhang
	Chongxi Zhao
	Yuhong Feng
	Yongqiang Liu

Link: https://lkml.kernel.org/r/20220401024856.767-3-yejiajian2018@email.szu.edu.cn
Signed-off-by: Jiajian Ye <yejiajian2018@email.szu.edu.cn>
Cc: Chongxi Zhao <zhaochongxi2019@email.szu.edu.cn>
Cc: Shenghong Han <hanshenghong2019@email.szu.edu.cn>
Cc: Yinan Zhang <zhangyinan2019@email.szu.edu.cn>
Cc: Yixuan Cao <caoyixuan2019@email.szu.edu.cn>
Cc: Yongqiang Liu <liuyongqiang13@huawei.com>
Cc: Yuhong Feng <yuhongf@szu.edu.cn>
Cc: Haowen Bai <baihaowen@meizu.com>
Cc: Sean Anderson <seanga2@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
2022-04-28 23:15:57 -07:00
..
damon Docs/damon: update outdated term 'regions update interval' 2022-03-22 15:57:12 -07:00
.gitignore .gitignore: add SPDX License Identifier 2020-03-25 11:50:48 +01:00
active_mm.rst docs/vm: fix 'mm_count' vs 'mm_users' counter confusion 2020-10-13 18:38:32 -07:00
arch_pgtable_helpers.rst mm: ptep_clear() page table helper 2022-01-15 16:30:28 +02:00
balance.rst docs/vm: rename documentation files to .rst 2018-04-16 14:18:15 -06:00
free_page_reporting.rst mm/page_reporting: add free page reporting documentation 2020-04-07 10:43:39 -07:00
frontswap.rst frontswap: remove frontswap_shrink 2022-01-22 08:33:38 +02:00
highmem.rst docs/vm: rename documentation files to .rst 2018-04-16 14:18:15 -06:00
hmm.rst mm/migrate.c: remove MIGRATE_PFN_LOCKED 2021-11-11 09:34:35 -08:00
hugetlbfs_reserv.rst docs/vm: Minor editorial changes in the THP and hugetlbfs 2019-04-30 06:34:40 -06:00
hwpoison.rst x86/mce: Remove the tolerance level control 2022-02-23 11:09:25 +01:00
index.rst mm: remove cleancache 2022-01-22 08:33:38 +02:00
ksm.rst docs: get rid of :c:type explicit declarations for structs 2020-10-15 07:49:40 +02:00
memory-model.rst docs: remove description of DISCONTIGMEM 2021-06-29 10:53:55 -07:00
mmu_notifier.rst docs/vm: trivial fixes to several spelling mistakes 2020-10-22 16:11:04 -06:00
numa.rst docs: cgroup-v1: add it to the admin-guide book 2019-07-15 11:03:02 -03:00
overcommit-accounting.rst docs/vm: clarify overcommit amount sysctl behavior 2021-12-16 15:53:22 -07:00
page_frags.rst docs: vm: page_frags.rst: Fix the reference of stale function 2020-05-15 11:34:55 -06:00
page_migration.rst mm: migrate: correct the hugetlb migration stats 2022-01-15 16:30:30 +02:00
page_owner.rst tools/vm/page_owner_sort.c: support sorting blocks by multiple keys 2022-04-28 23:15:57 -07:00
page_table_check.rst docs/vm: Fix typo in *harden* 2022-01-27 11:22:34 -07:00
remap_file_pages.rst docs/vm: rename documentation files to .rst 2018-04-16 14:18:15 -06:00
slub.rst mm/slub: clarify verification reporting 2021-06-16 09:24:42 -07:00
split_page_table_lock.rst Documentation: fix typos in split page table lock description 2021-01-18 13:27:18 -07:00
transhuge.rst mm: gup: remove FOLL_SPLIT 2021-04-30 11:20:37 -07:00
unevictable-lru.rst mm/munlock: update Documentation/vm/unevictable-lru.rst 2022-04-01 11:46:09 -07:00
vmalloced-kernel-stacks.rst docs/vm: add vmalloced-kernel-stacks document 2022-01-15 16:30:28 +02:00
z3fold.rst docs/vm: rename documentation files to .rst 2018-04-16 14:18:15 -06:00
zsmalloc.rst docs/vm: rename documentation files to .rst 2018-04-16 14:18:15 -06:00