Lines Matching refs:adj
779 * Keep track of the number of hidden procs, to balance oom adj
3859 // Skip process if it doesn't meet our oom adj requirement.
6550 // adj level. Not sure what to do about this, but at least
7754 int adj = proc.setAdj;
7755 if (adj >= worstType && !proc.killedBackground) {
7756 Slog.w(TAG, "Killing " + proc + " (adj " + adj + "): " + reason);
7758 proc.processName, adj, reason);
7802 final int adj = proc.setAdj;
7803 if (adj > belowAdj && !proc.killedBackground) {
7804 Slog.w(TAG, "Killing " + proc + " (adj " + adj + "): " + reason);
7806 proc.pid, proc.processName, adj, reason);
9030 static int oomAdjToImportance(int adj, ActivityManager.RunningAppProcessInfo currApp) {
9031 if (adj >= ProcessList.HIDDEN_APP_MIN_ADJ) {
9033 currApp.lru = adj - ProcessList.HIDDEN_APP_MIN_ADJ + 1;
9036 } else if (adj >= ProcessList.SERVICE_B_ADJ) {
9038 } else if (adj >= ProcessList.HOME_APP_ADJ) {
9043 } else if (adj >= ProcessList.SERVICE_ADJ) {
9045 } else if (adj >= ProcessList.HEAVY_WEIGHT_APP_ADJ) {
9047 } else if (adj >= ProcessList.PERCEPTIBLE_APP_ADJ) {
9049 } else if (adj >= ProcessList.VISIBLE_APP_ADJ) {
9070 int adj = app.curAdj;
9071 outInfo.importance = oomAdjToImportance(adj, outInfo);
10388 pw.println(String.format("%s%s #%2d: adj=%s/%s%s trm=%2d %s (%s)",
10668 pw.println(" --oom: only show processes organized by oom adj.");
12973 int adj;
12980 adj = ProcessList.FOREGROUND_APP_ADJ;
12988 adj = ProcessList.FOREGROUND_APP_ADJ;
12997 adj = ProcessList.FOREGROUND_APP_ADJ;
13004 adj = ProcessList.FOREGROUND_APP_ADJ;
13010 adj = hiddenAdj;
13024 if (adj > ProcessList.VISIBLE_APP_ADJ) {
13025 adj = ProcessList.VISIBLE_APP_ADJ;
13034 if (adj > ProcessList.PERCEPTIBLE_APP_ADJ) {
13035 adj = ProcessList.PERCEPTIBLE_APP_ADJ;
13054 if (adj == hiddenAdj && !app.hasActivities) {
13056 adj = clientHiddenAdj;
13061 adj = emptyAdj;
13067 if (adj > ProcessList.PERCEPTIBLE_APP_ADJ) {
13070 adj = ProcessList.PERCEPTIBLE_APP_ADJ;
13076 adj = ProcessList.PERCEPTIBLE_APP_ADJ;
13088 if (adj > ProcessList.HEAVY_WEIGHT_APP_ADJ && app == mHeavyWeightProcess) {
13090 adj = ProcessList.HEAVY_WEIGHT_APP_ADJ;
13096 if (adj > ProcessList.HOME_APP_ADJ && app == mHomeProcess) {
13099 adj = ProcessList.HOME_APP_ADJ;
13105 if (adj > ProcessList.PREVIOUS_APP_ADJ && app == mPreviousProcess
13110 adj = ProcessList.PREVIOUS_APP_ADJ;
13116 if (false) Slog.i(TAG, "OOM " + app + ": initial adj=" + adj
13124 app.curRawAdj = app.nonStoppingAdj = adj;
13128 if (adj > ProcessList.BACKUP_APP_ADJ) {
13130 adj = ProcessList.BACKUP_APP_ADJ;
13136 if (app.services.size() != 0 && (adj > ProcessList.FOREGROUND_APP_ADJ
13142 while (jt.hasNext() && adj > ProcessList.FOREGROUND_APP_ADJ) {
13150 if (adj > ProcessList.SERVICE_ADJ) {
13158 if (adj > ProcessList.SERVICE_ADJ) {
13159 adj = ProcessList.SERVICE_ADJ;
13167 if (adj > ProcessList.SERVICE_ADJ) {
13175 if (s.connections.size() > 0 && (adj > ProcessList.FOREGROUND_APP_ADJ
13179 adj > ProcessList.FOREGROUND_APP_ADJ) {
13181 for (int i=0; i<clist.size() && adj > ProcessList.FOREGROUND_APP_ADJ; i++) {
13191 int clientAdj = adj;
13227 if (adj > clientAdj) {
13231 clientAdj = adj;
13240 if (adj > clientAdj) {
13243 clientAdj = adj;
13260 if (adj > clientAdj) {
13274 adj = clientAdj;
13277 && adj > ProcessList.PERCEPTIBLE_APP_ADJ) {
13278 adj = ProcessList.PERCEPTIBLE_APP_ADJ;
13280 adj = clientAdj;
13283 if (adj > ProcessList.VISIBLE_APP_ADJ) {
13284 adj = ProcessList.VISIBLE_APP_ADJ;
13312 if (a != null && adj > ProcessList.FOREGROUND_APP_ADJ &&
13315 adj = ProcessList.FOREGROUND_APP_ADJ;
13324 app.adjSourceOom = adj;
13338 if (adj > hiddenAdj) {
13339 adj = hiddenAdj;
13345 if (app.pubProviders.size() != 0 && (adj > ProcessList.FOREGROUND_APP_ADJ
13348 while (jt.hasNext() && (adj > ProcessList.FOREGROUND_APP_ADJ
13352 i >= 0 && (adj > ProcessList.FOREGROUND_APP_ADJ
13387 if (adj > clientAdj) {
13392 adj = clientAdj > ProcessList.FOREGROUND_APP_ADJ
13416 if (adj > ProcessList.FOREGROUND_APP_ADJ) {
13417 adj = ProcessList.FOREGROUND_APP_ADJ;
13428 if (adj == ProcessList.SERVICE_ADJ) {
13434 adj = ProcessList.SERVICE_B_ADJ;
13440 app.nonStoppingAdj = adj;
13444 if (adj > ProcessList.PERCEPTIBLE_APP_ADJ) {
13445 adj = ProcessList.PERCEPTIBLE_APP_ADJ;
13450 app.curRawAdj = adj;
13452 //Slog.i(TAG, "OOM ADJ " + app + ": pid=" + app.pid +
13453 // " adj=" + adj + " curAdj=" + app.curAdj + " maxAdj=" + app.maxAdj);
13454 if (adj > app.maxAdj) {
13455 adj = app.maxAdj;
13460 if (adj < ProcessList.HIDDEN_APP_MIN_ADJ) {
13470 if (adj < ProcessList.FOREGROUND_APP_ADJ) {
13472 } else if (adj < ProcessList.VISIBLE_APP_ADJ) {
13473 adj = ProcessList.VISIBLE_APP_ADJ;
13474 } else if (adj < ProcessList.PERCEPTIBLE_APP_ADJ) {
13475 adj = ProcessList.PERCEPTIBLE_APP_ADJ;
13476 } else if (adj < ProcessList.HIDDEN_APP_MIN_ADJ) {
13477 adj = ProcessList.HIDDEN_APP_MIN_ADJ;
13478 } else if (adj < ProcessList.HIDDEN_APP_MAX_ADJ) {
13479 adj++;
13484 if (importance == 0 || adj != app.curAdj || schedGroup != app.curSchedGroup) {
13485 app.curAdj = adj;
13492 } else if (adj >= ProcessList.HIDDEN_APP_MIN_ADJ) {
13494 } else if (adj >= ProcessList.SERVICE_B_ADJ) {
13496 } else if (adj >= ProcessList.HOME_APP_ADJ) {
13498 } else if (adj >= ProcessList.SERVICE_ADJ) {
13500 } else if (adj >= ProcessList.HEAVY_WEIGHT_APP_ADJ) {
13502 } else if (adj >= ProcessList.PERCEPTIBLE_APP_ADJ) {
13504 } else if (adj >= ProcessList.VISIBLE_APP_ADJ) {
13506 } else if (adj >= ProcessList.FOREGROUND_APP_ADJ) {
13835 " adj " + app.curAdj + ": " + app.adjType);
13839 Slog.w(TAG, "Failed setting oom adj of " + app + " to " + app.curAdj);
14013 // given it the current hidden adj; here we will just leave it
14014 // without stepping the hidden adj.
14246 // Now update the oom adj for all processes.