[profiler] log profiler: limit method instrumentation to selected methods (#5517)