查看 CPU 占用率
- 查看 CPU 占用排名前 5 的程序并间隔 3 秒输出
top -m 5 -t -d 3
(-m 最大数;-t 显示进程名;-d刷新间隔)
根据进程名查看其 CPU 占用率 `top -d 3| grep com.taobao.trip`
查看指定包的内存:
adb shell dumpsys meminfo | grep com.yinghd.circle
python中执行adb命令:
import os
os.system("adb shell dumpsys meminfo com.yinghd.circle")
查看手机是几核,即多少个CPU
$adb shell
$cat /proc/cpuinfo | grep processor