v5
2026-10-31
MGLRU回收跟踪点 · v5
将 vmscan tracepoint 移入 mm 本地头并传入 scan_control,为 MGLRU 的 scan_folios() 和 inc_max_seq() 增加追踪点。
原始补丁链接
子 Patch(6)
1/6
mm/memcontrol: drop unused vmscan tracepoint include
From: Ridong Chen chenridong@xiaomi.com memcontrol.c includes <trace/events/vmscan.h> but does not use any of the tracepoints or macros it defines: all tracepoints invoked here come from memcg.h an
2/6
mm/vmscan: move vmscan tracepoints to a local header
[mm/vmscan: move vmscan tracepoints to a local header] From: Ridong Chen chenridong@xiaomi.com Move include/trace/events/vmscan.h to mm/trace_vmscan.h so that the tracepoints can be extended to ref
3/6
mm/vmscan: move struct scan_control to a dedicated header
[mm/vmscan: move struct scan_control to a dedicated header] From: Ridong Chen chenridong@xiaomi.com The definition of struct scan_control has lived inline at the top of mm/vmscan.c. Move it out to
4/6
mm/vmscan: pass scan_control to the vmscan tracepoints
[mm/vmscan: pass scan_control to the vmscan tracepoints] From: Ridong Chen chenridong@xiaomi.com Several vmscan tracepoints spell out reclaim state as individual arguments, all of which the caller
5/6
mm/mglru: add tracepoint for scan_folios()
From: Ridong Chen chenridong@xiaomi.com MGLRU’s scan_folios() emits the classic-LRU tracepoint trace_mm_vmscan_lru_isolate(), which predates MGLRU. It reports the scan/isolate counts and the LRU ty
6/6
mm/mglru: add tracepoint for inc_max_seq()
From: Ridong Chen chenridong@xiaomi.com Aging in MGLRU advances max_seq via inc_max_seq(), creating a new youngest generation. There is currently no tracepoint on this path, so the moment a new gen