adb shell 查看当前进程和窗口信息可以使用如下命令:
>adb shell
>dumpsys window windows |grep "Window #"
显示信息如下:
2:打开AMS、WMS的命令行如下:
adb shell dumpsys activity log x on
adb shell dumpsys window -d enable a
3:查看屏幕分辨率和GPU频率
adb shell “cat /proc/gpufreq/gpufreq_opp_dump”
还有wm size,adb shell wm size
4:
adb shell wm size WXH 命令是按witch x hight 设置分辨率。如果分辨率设置的过大,图标会变大,反之则变小
adb shell wm size reset 命令是将分辨率设置为LCD原始分辨率
5:抓起loading 和fps 和freq
adb shell "setprop debug.egl.traceGpuCompletion 1"
adb shell "setprop debug.atrace.tags.enableflags 0x3fe"
adb shell "setprop debug.egl.trace systrace"
adb shell "stop;start"
2,请帮忙抓一下卡顿场景的GPU loading 和freq和FPs, 可以同时起三个命令行抓取,把得到的结果提供给我们。
// loading
adb shell "while(true) ; do cat /d/ged/hal/gpu_utilization;sleep 0.1; done"
// freq
adb shell "while(true) ; do cat /proc/gpufreq/gpufreq_var_dump | grep g_cur_gpu_freq; sleep 1; done"
// FPS
adb shell "while(true) ; do cat /d/ged/hal/ged_kpi; sleep 1; done"
6:读取Settings db中的属性值
adb shell settings list global | grep game
adb shell settings list secure| grep game
7:使用adb命令过滤logcat中的命令信息。
(1) adb shell findstr | grep service_to_fd
(2)adb shell
logcat | grep service_to_fd
Line 526: 12-06 15:11:32.074 1526 1526 I ADB_SERVICES: service_to_fd shell:am start -W -S 'com.android.contacts/.activities.PeopleActivity'
Line 2430: 12-06 15:12:05.530 1526 1526 I ADB_SERVICES: service_to_fd shell:dumpsys -t 30 meminfo --package com.android.contacts
Line 2433: 12-06 15:12:06.127 1526 1526 I ADB_SERVICES: service_to_fd shell:am force-stop 'com.android.contacts'
因篇幅问题不能全部显示,请点此查看更多更全内容