adb shell dumpsys package [options]

显示包相关信息,使用-h查看options如下:

adb shell dumpsys [options]操作实例讲解-----(二)_数据库

-f:打印内嵌过滤器详细信息

--checkin:显示一个checkin文件

[cmd]肯能是下面列表中的一个:

l[ibraries]:对当前所知道的共享库进行列表显示

f[ibraries]:对当前设备功能列表展示

k[eysets]:输出所知键盘

r[esolvers]:显示内部解析器

perm[issions]:显示权限

permissions[name ...]:显示声明且已有权限

pref[erred]:输出首选包设置

preferred-xml[--full]:把首选包设置以xml格式输出

prov[iders]:显示内容供应商

p[ackages]:显示已安装的包

s[hared-users]:显示共享用户ID

m[essages]:输出收集的运行数据信息

v[erifiers]:输出包验证信息

d[omain-perferred-apps]:输出域名首选应用

i[ntent-filter-verifiers]|ifv:输出内部过滤验证信息

version:输出数据库版本新

write:写入当前设置信息

installs:安装会话的详细信息

check-permission<permission> <package> [<user>]:检查pkg是否持有权限

<package.name>:给定包信息

下面给出命令操作的几个实例,其他命令使用方式是一样的:

adb shell dumpsys package -f: 打印内嵌过滤器详细信息

adb shell dumpsys [options]操作实例讲解-----(二)_android_02

adb shell dumpsys package k: 输出所知键盘信息

adb shell dumpsys [options]操作实例讲解-----(二)_dumpsys package操作说明_03

adb shell dumpsys package version: 输出数据库版本信息

adb shell dumpsys [options]操作实例讲解-----(二)_dumpsys gfxinfo操作实例_04

adb shell dumpsys package p: 显示已安装的包

adb shell dumpsys [options]操作实例讲解-----(二)_数据库_05

adb shell dumpsys package io.appium.unlock: 显示安装包io.appium.unlock的详细信息

adb shell dumpsys [options]操作实例讲解-----(二)_dumpsys gfxinfo操作实例_06

adb shell dumpsys processinfo

显示进程信息,本设备为空

adb shell dumpsys [options]操作实例讲解-----(二)_dumpsys gfxinfo操作实例_07

adb shell dumpsys procstats

显示进程统计信息:

 adb shell dumpsys [options]操作实例讲解-----(二)_android_08

 

adbshell dumpsys gfxinfo <PACKAGE_NAME>

显示有关与录制阶段期间发生的动画帧相关的性能信息:

Applications Graphics Acceleration Info:

Uptime: 45715525 Realtime: 51066627



** Graphics info for pid 4830 [com.ximalaya.ting.android] **



Stats since: 45636040497798ns

Total frames rendered: 274

Janky frames: 153 (55.84%)

90th percentile: 46ms

95th percentile: 61ms

99th percentile: 93ms

Number Missed Vsync: 14

Number High input latency: 0

Number Slow UI thread: 50

Number Slow bitmap uploads: 16

Number Slow issue draw commands: 119



Caches:

Current memory usage / total memory usage (bytes):

TextureCache 12986312 / 75497472

LayerCache 0 / 50331648 (numLayers = 0)

Layers total 0 (numLayers = 0)

RenderBufferCache 0 / 8388608

GradientCache 0 / 1048576

PathCache 0 / 33554432

TessellationCache 13128 / 1048576

TextDropShadowCache 0 / 6291456

PatchCache 576 / 131072

FontRenderer 0 A8 1048576 / 1048576

FontRenderer 0 RGBA 0 / 0

FontRenderer 0 total 1048576 / 1048576

Other:

FboCache 0 / 2

Total memory usage:

14048592 bytes, 13.40 MB



Profile data in ms:



com.ximalaya.ting.android/com.ximalaya.ting.android.activity.MainActivity/android.view.ViewRootImpl@34a4506 (visibility=0)

Stats since: 45636040497798ns

Total frames rendered: 274

Janky frames: 153 (55.84%)

90th percentile: 46ms

95th percentile: 61ms

99th percentile: 93ms

Number Missed Vsync: 14

Number High input latency: 0

Number Slow UI thread: 50

Number Slow bitmap uploads: 16

Number Slow issue draw commands: 119



View hierarchy:



com.ximalaya.ting.android/com.ximalaya.ting.android.activity.MainActivity/android.view.ViewRootImpl@34a4506

295 views, 286.13 kB of display lists





Total ViewRootImpl: 1

Total Views: 295

Total DisplayList: 286.13 kB