1 頁 (共 1 頁)

AMD CPU 效能調整

發表於 : 週二 9月 08, 2020 5:52 pm
chengpercy
實做於
主機:技嘉 R181-Z90
系統:Ubuntu 20.04.1 LTS

BIOS 設定:

最高時脈 AMD CBS \ CPU Common \ Performance \ Custon Core Pstates \ Custon Pstates1 > Disabled
核心數量 AMD CBS \ CPU Common \ Performance \ CCD/Core/Thread Enablement \ SMT Control > Disabled

核心數量 (相對於 INTEL 的 HT) 可以不用關

OS 設定:

安裝 cpupower
apt install linux-oem-5.6-tools-common
apt install linux-tools-generic linux-cloud-tools-generic


關閉 C-states 與 P-states
cpupower idle-set -d 2

看看跑的時脈有沒有比較高了
watch -n 1 "cat /proc/cpuinfo | grep MHz"

Re: AMD CPU 效能調整

發表於 : 週三 3月 02, 2022 2:48 pm
chengpercy
看 CPU 資訊的指令
cat /proc/cpuinfo
lscpu

看 CPU 的運行頻率
cat /proc/cpuinfo | grep MHz

每秒自動取得目前的CPU頻率
watch -n 1 "cat /proc/cpuinfo | grep MHz"
watch -n 1 "lscpu"

BIOS 設定 (忘了這是 AMD 還是 Intel 的)
Advanced 下面的 CPU Configuration
Core Performance Boost > auto
Global C-state Control > disabled

新杰資訊小顧說
cpupower idle-set -d 2 -> 是 debian 用的,對 ubuntu 沒有效果

安裝燒機軟體 s-tui
apt install stress
apt install python3-pip
pip3 install s-tui


執行 s-tui
s-tui
Stress Options 設定
Malloc() / Free() worker count: 48
Bytes per malloc*: 10G

這台主機有 512G 的記憶體,所以上面設為 48*10G = 480G
新杰說不要設超過記憶體上限

cpupower frequency-info
可以看到 cpu 預設是跑 ondemand 模式

改跑 performance 模式
cpupower frequency-set -g performance

看看跑的時脈有沒有比較高了
watch -n 1 "cat /proc/cpuinfo | grep MHz"

!! 重開機後會回復原本的 ondemand 模式