187
edits
| Line 15: | Line 15: | ||
Killing the main process kills all child processes and effectively reboots the phone, so we never want to kill the main process. Therefore, the main process runs with oom_adj 0. | Killing the main process kills all child processes and effectively reboots the phone, so we never want to kill the main process. Therefore, the main process runs with oom_adj 0. | ||
Most processes run with oom_adj 2 while they're in the foreground. | Most child processes run with oom_adj 2 while they're in the foreground. Child processes in the background run with oom_adj between 3 and 6 (inclusive). Exactly what oom_adj a child process while in the background gets depends on a number of factors, such as whether it's playing sound, whether it's the homescreen app, and so on. | ||
=== Debugging an OOM crash === | === Debugging an OOM crash === | ||
edits