查看完整版本: 執行後輸出CPU使用率
頁: [1]

phes10529 發表於 2019-6-4 04:06 PM

執行後輸出CPU使用率

系統是使用CentOS Linux release 7.3.1611

gcc -fopenmp main.c -o test
執行
./test
想要顯示CPU使用率要怎麼用呢??

code<div></div>

stephenwei_lu 發表於 2019-6-5 03:08 PM

這個?

https://stackoverflow.com/questions/1221555/retrieve-cpu-usage-and-memory-usage-of-a-single-process-on-linux

z1090128 發表於 2019-8-30 08:38 PM

top或htop都可以,htop可以顯示較完整的資訊
頁: [1]