0 full gc时cpu idle_【cpuidle】计算每个cpu进入idle的时间

0 full gc时cpu idle_【cpuidle】计算每个cpu进入idle的时间参考内核文档 Supportingmu sys devices system cpu cpuidleThecu

参考内核文档

Supporting multiple CPU idle levels in kernel

cpuidle sysfs

System global cpuidle related information and tunables are under

/sys/devices/system/cpu/cpuidle

The current interfaces in this directory has self-explanatory names:

* current_driver

* current_governor_ro

With cpuidle_sysfs_switch boot option (meant for developer testing)

following objects are visible instead.

* current_driver

* available_governors

* current_governor

In this case users can switch the governor at run time by writing

to current_governor.

Per logical CPU specific cpuidle information are under

/sys/devices/system/cpu/cpuX/cpuidle

for each online cpu X

——————————————————————————–

# ls -lR /sys/devices/system/cpu/cpu0/cpuidle/

/sys/devices/system/cpu/cpu0/cpuidle/:

total 0

drwxr-xr-x 2 root root 0 Feb 8 10:42 state0

drwxr-xr-x 2 root root 0 Feb 8 10:42 state1

drwxr-xr-x 2 root root 0 Feb 8 10:42 state2

drwxr-xr-x 2 root root 0 Feb 8 10:42 state3

/sys/devices/system/cpu/cpu0/cpuidle/state0:

total 0

-r–r–r– 1 root root 4096 Feb 8 10:42 desc

-rw-r–r– 1 root root 4096 Feb 8 10:42 disable

-r–r–r– 1 root root 4096 Feb 8 10:42 latency

-r–r–r– 1 root root 4096 Feb 8 10:42 name

-r–r–r– 1 root root 4096 Feb 8 10:42 power

-r–r–r– 1 root root 4096 Feb 8 10:42 residency

-r–r–r– 1 root root 4096 Feb 8 10:42 time

-r–r–r– 1 root root 4096 Feb 8 10:42 usage

/sys/devices/system/cpu/cpu0/cpuidle/state1:

total 0

-r–r–r– 1 root root 4096 Feb 8 10:42 desc

-rw-r–r– 1 root root 4096 Feb 8 10:42 disable

-r–r–r– 1 root root 4096 Feb 8 10:42 latency

-r–r–r– 1 root root 4096 Feb 8 10:42 name

-r–r–r– 1 root root 4096 Feb 8 10:42 power

-r–r–r– 1 root root 4096 Feb 8 10:42 residency

-r–r–r– 1 root root 4096 Feb 8 10:42 time

-r–r–r– 1 root root 4096 Feb 8 10:42 usage

/sys/devices/system/cpu/cpu0/cpuidle/state2:

total 0

-r–r–r– 1 root root 4096 Feb 8 10:42 desc

-rw-r–r– 1 root root 4096 Feb 8 10:42 disable

-r–r–r– 1 root root 4096 Feb 8 10:42 latency

-r–r–r– 1 root root 4096 Feb 8 10:42 name

-r–r–r– 1 root root 4096 Feb 8 10:42 power

-r–r–r– 1 root root 4096 Feb 8 10:42 residency

-r–r–r– 1 root root 4096 Feb 8 10:42 time

-r–r–r– 1 root root 4096 Feb 8 10:42 usage

/sys/devices/system/cpu/cpu0/cpuidle/state3:

total 0

-r–r–r– 1 root root 4096 Feb 8 10:42 desc

-rw-r–r– 1 root root 4096 Feb 8 10:42 disable

-r–r–r– 1 root root 4096 Feb 8 10:42 latency

-r–r–r– 1 root root 4096 Feb 8 10:42 name

-r–r–r– 1 root root 4096 Feb 8 10:42 power

-r–r–r– 1 root root 4096 Feb 8 10:42 residency

-r–r–r– 1 root root 4096 Feb 8 10:42 time

-r–r–r– 1 root root 4096 Feb 8 10:42 usage

——————————————————————————–

* desc : Small description about the idle state (string)

* disable : Option to disable this idle state (bool) -> see note below

* latency : Latency to exit out of this idle state (in microseconds)

* residency : Time after which a state becomes more effecient than any

shallower state (in microseconds)

* name : Name of the idle state (string)

* power : Power consumed while in this idle state (in milliwatts)

* time : Total time spent in this idle state (in microseconds)

* usage : Number of times this state was entered (count)

Note:

The behavior and the effect of the disable variable depends on the

implementation of a particular governor. In the ladder governor, for

example, it is not coherent, i.e. if one is disabling a light state,

then all deeper states are disabled as well, but the disable variable

does not reflect it. Likewise, if one enables a deep state but a lighter

state still is disabled, then this has no effect.

其中time显示了每个idle阶段的时间长短。

前后两次idle/state*/time的时间即是进入idle的时间。

版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请联系我们举报,一经查实,本站将立刻删除。

发布者:全栈程序员-站长,转载请注明出处:https://javaforall.net/233943.html原文链接:https://javaforall.net

(0)
全栈程序员-站长的头像全栈程序员-站长


相关推荐

  • Js判断数组中是否存在某个元素「建议收藏」

    Js判断数组中是否存在某个元素「建议收藏」方法一:indexOf(item,start);Item:要查找的值;start:可选的整数参数,缺省则从起始位子开始查找。indexOf();返回元素在数组中的位置,如果没有则返回-1;例子:vararr=[‘aaa’,’bbb’,’ccc’,’ddd’,’eee’];  vara=arr.indexOf(‘ddd’);  console.log(a);  //3  varb=arr.indexOf(‘d’);  console.log(b);  //-1  我通常的用法:if(

    2022年10月19日
    4
  • pychar激活码【注册码】「建议收藏」

    pychar激活码【注册码】,https://javaforall.net/100143.html。详细ieda激活码不妨到全栈程序员必看教程网一起来了解一下吧!

    2022年3月20日
    36
  • tomcat8安装及配置教程_vrrp配置实例

    tomcat8安装及配置教程_vrrp配置实例1.下载tomcat8,官网地址:http://tomcat.apache.org/根据自己电脑的系统,下载对应的版本zip,我下载的是window64位的zip包下一步:2.解压缩apache-tomcat-8.5.11-windows-x64.zip到D盘3.环境变量配置:(请先看文章结尾)3.1系统变量,新增 CATALINA_HOME,地址就是刚才文件夹,不需要带/bin3.2…

    2026年1月21日
    4
  • Android应用开发揭秘

    Android应用开发揭秘《Android应用开发揭秘》                                              ///////http://www.iteye.com/wiki/hzbook/2249-Android  书名:Android应用开发揭秘作者:杨丰盛出版社:机械工业出版社ISBN:9787111291954出版日期:2010年3月(1版2次)…

    2022年4月28日
    43
  • 日志格式规范「建议收藏」

    日志格式规范「建议收藏」1简介在程序中写日志是一件非常重要,但是很容易被开发人员忽视的地方。写好程序的日志可以帮助我们大大减轻后期维护压力。在实际的工作中,开发人员往往迫于巨大时间压力,而写日志又是一个非常繁琐的事情,往往没有引起足够的重视。开发人员应在一开始就养成良好的日志撰写习惯,并且应在实际的开发工作中为写日志预留足够的时间。1.1日志的作用一般程序日志出自下面几个方面的需求:1.记…

    2022年5月1日
    62
  • LaTex中输入空格以及换行

    LaTex中输入空格以及换行1.使用\表示空格以及调整空格的大小quad空格 a\qquadb 两个m的宽度 quad空格 a\quadb 一个m的宽度 大空格 a\b 1/3m宽度 中等空格 a\;b 2/7m宽度 小空格 a\,b 1/6m宽度 没有空格 ab …

    2022年5月15日
    449

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注

关注全栈程序员社区公众号