Show flamegraphs only for slow or long running functions.
This is like using bcc EBPF funcslower or funclatency tool. A threshold can be set such that when exceeded, stacktraces will be emitted.
Might be useful that there's a way to get func -> count, time (histogram breakdown) independently of flamegraphs