Home
last modified time | relevance | path

Searched hist:"7 cd5738d0d8bb192fc86736ac7fb4a6cdb57f957" (Results 1 – 3 of 3) sorted by relevance

/linux/tools/perf/util/
H A Dprobe-finder.hdiff 7cd5738d0d8bb192fc86736ac7fb4a6cdb57f957 Fri Sep 18 10:01:41 CEST 2020 Masami Hiramatsu <mhiramat@kernel.org> perf probe: Fall back to debuginfod query if debuginfo and source not found locally

Since 'perf probe' heavily depends on debuginfo, debuginfod gives us
many benefits on the 'perf probe' command on remote machine.

Especially, this will be helpful for the embedded devices which will not
have enough storage, or boot with a cross-build kernel whose source code
is in the host machine.

This will work as similar to commit c7a14fdcb3fa7736 ("perf build-ids:
Fall back to debuginfod query if debuginfo not found")

Tested with:

(host) $ cd PATH/TO/KBUILD/DIR/
(host) $ debuginfod -F .
...

(remote) # perf probe -L vfs_read
Failed to find the path for the kernel: No such file or directory
Error: Failed to show lines.

(remote) # export DEBUGINFOD_URLS="http://$HOST_IP:8002/"
(remote) # perf probe -L vfs_read
<vfs_read@...>
0 ssize_t vfs_read(struct file *file, char __user *buf, size_t count, loff_t *pos)
{
2 ssize_t ret;

if (!(file->f_mode & FMODE_READ))
return -EBADF;
6 if (!(file->f_mode & FMODE_CAN_READ))
return -EINVAL;
8 if (unlikely(!access_ok(buf, count)))
return -EFAULT;

11 ret = rw_verify_area(READ, file, pos, count);
12 if (ret)
return ret;
if (count > MAX_RW_COUNT)
...

(remote) # perf probe -a "vfs_read count"
Added new event:
probe:vfs_read (on vfs_read with count)

(remote) # perf probe -l
probe:vfs_read (on vfs_read@ksrc/linux/fs/read_write.c with count)

Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org>
Reviewed-by: Frank Ch. Eigler <fche@redhat.com>
Cc: Aaron Merey <amerey@redhat.com>
Cc: Daniel Thompson <daniel.thompson@linaro.org>
Link: http://lore.kernel.org/lkml/160041610083.912668.13659563860278615846.stgit@devnote2
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
H A Dprobe-finder.cdiff 7cd5738d0d8bb192fc86736ac7fb4a6cdb57f957 Fri Sep 18 10:01:41 CEST 2020 Masami Hiramatsu <mhiramat@kernel.org> perf probe: Fall back to debuginfod query if debuginfo and source not found locally

Since 'perf probe' heavily depends on debuginfo, debuginfod gives us
many benefits on the 'perf probe' command on remote machine.

Especially, this will be helpful for the embedded devices which will not
have enough storage, or boot with a cross-build kernel whose source code
is in the host machine.

This will work as similar to commit c7a14fdcb3fa7736 ("perf build-ids:
Fall back to debuginfod query if debuginfo not found")

Tested with:

(host) $ cd PATH/TO/KBUILD/DIR/
(host) $ debuginfod -F .
...

(remote) # perf probe -L vfs_read
Failed to find the path for the kernel: No such file or directory
Error: Failed to show lines.

(remote) # export DEBUGINFOD_URLS="http://$HOST_IP:8002/"
(remote) # perf probe -L vfs_read
<vfs_read@...>
0 ssize_t vfs_read(struct file *file, char __user *buf, size_t count, loff_t *pos)
{
2 ssize_t ret;

if (!(file->f_mode & FMODE_READ))
return -EBADF;
6 if (!(file->f_mode & FMODE_CAN_READ))
return -EINVAL;
8 if (unlikely(!access_ok(buf, count)))
return -EFAULT;

11 ret = rw_verify_area(READ, file, pos, count);
12 if (ret)
return ret;
if (count > MAX_RW_COUNT)
...

(remote) # perf probe -a "vfs_read count"
Added new event:
probe:vfs_read (on vfs_read with count)

(remote) # perf probe -l
probe:vfs_read (on vfs_read@ksrc/linux/fs/read_write.c with count)

Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org>
Reviewed-by: Frank Ch. Eigler <fche@redhat.com>
Cc: Aaron Merey <amerey@redhat.com>
Cc: Daniel Thompson <daniel.thompson@linaro.org>
Link: http://lore.kernel.org/lkml/160041610083.912668.13659563860278615846.stgit@devnote2
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
H A Dprobe-event.cdiff 7cd5738d0d8bb192fc86736ac7fb4a6cdb57f957 Fri Sep 18 10:01:41 CEST 2020 Masami Hiramatsu <mhiramat@kernel.org> perf probe: Fall back to debuginfod query if debuginfo and source not found locally

Since 'perf probe' heavily depends on debuginfo, debuginfod gives us
many benefits on the 'perf probe' command on remote machine.

Especially, this will be helpful for the embedded devices which will not
have enough storage, or boot with a cross-build kernel whose source code
is in the host machine.

This will work as similar to commit c7a14fdcb3fa7736 ("perf build-ids:
Fall back to debuginfod query if debuginfo not found")

Tested with:

(host) $ cd PATH/TO/KBUILD/DIR/
(host) $ debuginfod -F .
...

(remote) # perf probe -L vfs_read
Failed to find the path for the kernel: No such file or directory
Error: Failed to show lines.

(remote) # export DEBUGINFOD_URLS="http://$HOST_IP:8002/"
(remote) # perf probe -L vfs_read
<vfs_read@...>
0 ssize_t vfs_read(struct file *file, char __user *buf, size_t count, loff_t *pos)
{
2 ssize_t ret;

if (!(file->f_mode & FMODE_READ))
return -EBADF;
6 if (!(file->f_mode & FMODE_CAN_READ))
return -EINVAL;
8 if (unlikely(!access_ok(buf, count)))
return -EFAULT;

11 ret = rw_verify_area(READ, file, pos, count);
12 if (ret)
return ret;
if (count > MAX_RW_COUNT)
...

(remote) # perf probe -a "vfs_read count"
Added new event:
probe:vfs_read (on vfs_read with count)

(remote) # perf probe -l
probe:vfs_read (on vfs_read@ksrc/linux/fs/read_write.c with count)

Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org>
Reviewed-by: Frank Ch. Eigler <fche@redhat.com>
Cc: Aaron Merey <amerey@redhat.com>
Cc: Daniel Thompson <daniel.thompson@linaro.org>
Link: http://lore.kernel.org/lkml/160041610083.912668.13659563860278615846.stgit@devnote2
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>