Oprofile中的基本疑问

发布于 2024-09-08 03:05:21 字数 203 浏览 1 评论 0原文

我正在尝试使用 oprofile 分析我的软件(在 Linux 中)。我的软件由用户空间和内核模块组成。首先我的疑问是 --separate=kernel 选项的作用是什么?如果没有该选项运行会有什么区别?我确实尝试过查看它,但没有发现任何区别。您能发布一个例子吗?

我无法在没有 --seperate=kernel 选项的情况下分析内核模块吗?

谢谢, 巴拉

I am trying to profile my software (in Linux) with oprofile. My software consists of both userspace and kernel module. First my doubt is what does the --separate=kernel option do? What will be the difference when running without that option? I did try to see it but couldn't find any difference. Could you please post an example?

Can't i profile a kernel module without the --seperate=kernel option?

Thanks,
Bala

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

痴梦一场 2024-09-15 03:05:21

在 oprofile 中,当与选项 --seperate=kernel 一起使用时,它将每个应用程序的内核和内核模块分开。
--seperate='library' 根据应用程序分隔动态链接对象的样本。

内核、动态链接对象并不特定于我们想要单独分析的应用程序。但与此同时,我们的应用程序在其中花费了大量时间。
因此 --seperate 允许我们从我们感兴趣的应用程序的角度获取样本。它还可以根据各个线程提供样本。

可以通过向 opcontrol 提供 --vmlinux 选项来分析内核。

例如:- opcontrol --vmlinux=/boot/vmlinux-2.6.27.23-0.1-preempt

--seperate 是附加选项,允许我们以不同的分辨率查看样本。

In oprofile when used with option --seperate=kernel, it seperates the kernel and kernel modules per application.
--seperate='library' seperates the samples for the dynamically linked object per application basis.

kernel, dynamically linked object are just not specific to the application we want to profile alone. But at the same time our application spends considerable amount of time in them.
So --seperate allows one to get the samples from the point of view of the application we are interested in profiling. It can also give samples based on individual threads also.

Kernel can be profiled by providing --vmlinux option to opcontrol.

Ex:- opcontrol --vmlinux=/boot/vmlinux-2.6.27.23-0.1-preempt

--seperate is additional option that allows us to see the samples at different resolutions.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文