[性能优化] CPU电源管理pstate cstate

 

CPU的电源管理是会影响性能的。

pstate指CPU忙时的电源管理,为了省电会调节主频和电压。cstate是cpu闲时的电压管理。

 

详细资料见:

https://software.intel.com/en-us/blogs/2008/05/29/what-exactly-is-a-p-state-pt-1

https://www.thomas-krenn.com/en/wiki/Processor_P-states_and_C-states

【加星】https://software.intel.com/en-us/articles/power-management-states-p-states-c-states-and-package-c-states

 

linux与kernel如何针对电源管理进行调度:

https://www.kernel.org/doc/html/v4.12/admin-guide/kernel-parameters.html

https://www.kernel.org/doc/html/v4.12/admin-guide/pm/cpufreq.html

https://www.kernel.org/doc/html/v4.12/admin-guide/pm/intel_pstate.html

 

最简单的,直接关掉它的方法:(见红字)

intel_pstate=disable intel_idle.max_cstate=0 processor.max_cstate=0
[root@tong ~]# cat /proc/cmdline 
BOOT_IMAGE=/vmlinuz-3.10.0-693.21.4.el7.x86_64 root=UUID=027f3098-783a-491a-9b1a-4d78a910952a ro crashkernel=auto isolcpus=1,4,6,17,20,22 intel_pstate=disable intel_idle.max_cstate=0 processor.max_cstate=0 rhgb quiet

posted on 2020-01-10 16:08  toong  阅读(8712)  评论(0编辑  收藏  举报