Re: Profiling execution time for __alloc_pages_nodemask
From: Shivank Garg
Date: Wed May 12 2021 - 15:36:59 EST
>> Actually, I want to record the arguments for the memory allocator and
>> filter out the calls I don't need (which are creating noise).
>> For instance, I'm only interested in particular order and flags.
>BPF can do so too. You can either attach to kprobe or tracepoint, then
>filter out the calls by the function's parameters or tracepoint's
Thanks Yang for the suggestion, I'll try the BPF. Anyway my problem
was solved by the filter in custom tracepoints (for instance,
Also, I used trace_*_enabled() to first check if tracepoint is enabled
and take ktime_get() only after that. This solved my initial issue.
Thanks David, Yang and the Linux community for helping me identify my
issue and solve it.