【问题标题】:Wall time and cpu time in Linux command timeLinux命令时间中的wall time和cpu time
【发布时间】:2021-05-26 15:42:01
【问题描述】:

当我使用 Linux time 命令来测量运行一个命令所花费的时间时,下面哪个对应于 CPU 时间和 wall time?

real    3m13.792s
user    9m35.958s
sys 0m41.066s

【问题讨论】:

  • 你读过manual吗?无论如何,这不是一个编程问题,因此与 Stack Overflow 无关。

标签: linux time


【解决方案1】:

下面哪一项对应CPU时间

user是用户态的cpu时间,sys是内核态的cpu时间

还有挂壁时间?

real

【讨论】:

  • 在上面的例子中,wall (real) time 大于 cpu time (user or sys)。正常吗?
  • 两个个CPU工作一秒,cpu时间用了多少?
猜你喜欢
  • 2011-11-12
  • 2021-10-13
  • 1970-01-01
  • 1970-01-01
  • 2013-03-23
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
相关资源
最近更新 更多