如何衡量一个进程的单独CPU核心使用率? [英] How do I measure separate CPU core usage for a process?

查看:130
本文介绍了如何衡量一个进程的单独CPU核心使用率?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有什么方法可以衡量内核的特定进程CPU使用率吗?

我知道顶部可以很好地衡量内核的整个系统的CPU使用率和任务集可以提供有关允许该进程在哪个CPU内核上运行的信息. /p>

但是我如何通过CPU内核衡量特定进程的CPU使用率?

解决方案

您仍然可以在 top 中执行此操作.当 top 运行时,按键盘上的'1',它将显示每个内核的CPU使用率.

通过使特定进程在特定用户帐户下运行来限制显示的进程,并使用"u"类型限制该用户

Is there any way to measure a specific process CPU usage by cores?

I know top is good for measuring the whole system's CPU usage by cores and taskset can provide information about which CPU core is allowed for the process to run on.

But how do I measure a specific process' CPU usage by CPU cores?

解决方案

You can still do this in top. While top is running, press '1' on your keyboard, it will then show CPU usage per core.

Limit the processes shown by having that specific process run under a specific user account and use Type 'u' to limit to that user

这篇关于如何衡量一个进程的单独CPU核心使用率?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆