当前位置:网站首页>App hangs~

App hangs~

2022-06-23 05:18:00 xhBruce

The app hangs

android How to analyze process killing


Crash

tagNum keyword Parameter description Brief description
30039am_crash(User|1|5),(PID|1|5),(Process Name|3),(Flags|1|5),(Exception|3),(Message|3),(File|3),(Line|1|5)# Unhandled exception

ANR

tagNum keyword Parameter description Brief description
30008am_anr(User|1|5),(pid|1|5),(Package Name|3),(Flags|1|5),(reason|3)# Application Not Responding

am_proc_died

tagNum keyword Parameter description Brief description
30011am_proc_died(User|1|5),(PID|1|5),(Process Name|3),(OomAdj|1|5),(ProcState|1|5)# Application process died
30023am_kill(User|1|5),(PID|1|5),(Process Name|3),(OomAdj|1|5),(Reason|3)# Kill a process to reclaim memory.
frameworks/base/services/core/java/com/android/server/am/ActivityManagerService.java
frameworks/base/services/core/java/com/android/server/am/ProcessRecord.java
frameworks/base/core/java/android/app/ApplicationExitInfo.java

 Insert picture description here  Insert picture description here

  • The above is obvious crash、anr, relevant ApplicationExitInfo.REASON_ANRApplicationExitInfo.REASON_CRASH
     Insert picture description here
  • Sometimes it's just am_proc_died and wm_finish_activity

Case study

crash\anr

Low memory killing (LowMemoryKiller)

CPU High occupancy

am_kill : [0,22157,com.ximalaya.ting.android,900,excessive cpu 16720 during 300044 dur=2221553 limit=2]
ActivityManager: Killing 22157:com.ximalaya.ting.android/u0a239 (adj 900): excessive cpu 16720 during 300044 dur=2221553 limit=2
Zygote : Process 22157 exited due to signal 9 (Killed)

The process exits itself

Normal killing

installPackageLI/ deletePackageX And so on

Signal 9 commit suicide

09-07 16:53:03.027 1000 2566 2582 I Process : Sending signal. PID: 2566 SIG: 9
09-07 16:53:03.154 root 681 681 I Zygote : Process 2566 exited due to signal 9 (Killed)
09-07 16:53:03.167 1000 1734 4006 I ActivityManager: Process com.android.systemui (pid 2566) has died: pers PER
原网站

版权声明
本文为[xhBruce]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/174/202206230225032882.html