linux-perf-users.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3 0/3] perf maps: Improve the kcore maps merging
@ 2024-05-20  9:06 Leo Yan
  2024-05-20  9:06 ` [PATCH v3 1/3] perf maps: Sort kcore maps Leo Yan
                   ` (2 more replies)
  0 siblings, 3 replies; 11+ messages in thread
From: Leo Yan @ 2024-05-20  9:06 UTC (permalink / raw)
  To: Arnaldo Carvalho de Melo, Ian Rogers, Namhyung Kim, James Clark,
	Adrian Hunter, Athira Rajeev, Mark Rutland, Alexander Shishkin,
	Jiri Olsa, linux-perf-users, linux-kernel
  Cc: Leo Yan

This patch series follows up on the patch [1] to improve the sorting and
merging of kcore maps.

Since the kcore maps are not sorted, merging them into the kernel maps
causes mess, e.g. some kcore maps might be ignored. Patch 01 sorts the
kcore maps and ensures the subset region is placed ahead of the superset
region in the list.

Patch 02 uses maps__remove_maps() to remove the identical kernel map
(generated by reading symbols from '/proc/kallsyms') from the map list.
This can give us a neat list without interfered by old map data and is a
preparation for later relying puerly on kcore maps.

Patch 03 removes the kernel text section replacement. Alternatively,
it searches the kcore maps and finds the map for kernel text section,
then update the pointer 'machine->vmlinux_map'.

This patch series is based on the latest acme's perf-tool-next branch
and tested on Arm64 Hikey960 board.

[1] https://lore.kernel.org/linux-perf-users/438f8725-ef3f-462f-90e2-840cab478ee5@arm.com/T/#m7c86a69d43103cd0cb446b0993e47c36df0f40f2


Leo Yan (3):
  perf maps: Sort kcore maps
  perf maps: Remove the kernel text map with maps__remove_maps()
  perf maps: Remove the replacement of kernel map

 tools/perf/util/maps.c   |   4 +-
 tools/perf/util/maps.h   |   2 +-
 tools/perf/util/symbol.c | 136 ++++++++++++++++++++-------------------
 3 files changed, 74 insertions(+), 68 deletions(-)

-- 
2.34.1


^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2024-05-29  8:45 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-05-20  9:06 [PATCH v3 0/3] perf maps: Improve the kcore maps merging Leo Yan
2024-05-20  9:06 ` [PATCH v3 1/3] perf maps: Sort kcore maps Leo Yan
2024-05-22 10:31   ` Adrian Hunter
2024-05-25  9:29     ` Leo Yan
2024-05-28 15:00       ` James Clark
2024-05-29  8:45         ` Adrian Hunter
2024-05-20  9:06 ` [PATCH v3 2/3] perf maps: Remove the kernel text map with maps__remove_maps() Leo Yan
2024-05-22 11:27   ` Adrian Hunter
2024-05-20  9:06 ` [PATCH v3 3/3] perf maps: Remove the replacement of kernel map Leo Yan
2024-05-22  8:57   ` Adrian Hunter
2024-05-28 15:33   ` James Clark

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).