Lines Matching full:tasks
11 * When CPU, memory and IO are contended, tasks experience delays that
30 * In the SOME state of a given resource, one or more tasks are
32 * perform work, but the CPU may still be executing other tasks.
34 * In the FULL state of a given resource, all non-idle tasks are
48 * FULL means all non-idle tasks in the cgroup are delayed on the CPU
62 * The more tasks and available CPUs there are, the more work can be
65 * tasks and CPUs.
67 * Consider a scenario where 257 number crunching tasks are trying to
75 * Conversely, consider a scenario of 4 tasks and 4 CPUs where at any
76 * given time *one* of the tasks is delayed due to a lack of memory.
83 * we have to base our calculation on the number of non-idle tasks in
86 * delayed tasks to possible threads, and FULL is the share of possible
99 * For the 1 out of 4 memory-delayed tasks, this yields:
221 static bool test_state(unsigned int *tasks, enum psi_states state, bool oncpu) in test_state() argument
225 return unlikely(tasks[NR_IOWAIT]); in test_state()
227 return unlikely(tasks[NR_IOWAIT] && !tasks[NR_RUNNING]); in test_state()
229 return unlikely(tasks[NR_MEMSTALL]); in test_state()
231 return unlikely(tasks[NR_MEMSTALL] && in test_state()
232 tasks[NR_RUNNING] == tasks[NR_MEMSTALL_RUNNING]); in test_state()
234 return unlikely(tasks[NR_RUNNING] > oncpu); in test_state()
236 return unlikely(tasks[NR_RUNNING] && !oncpu); in test_state()
238 return tasks[NR_IOWAIT] || tasks[NR_MEMSTALL] || in test_state()
239 tasks[NR_RUNNING]; in test_state()
251 unsigned int tasks[NR_PSI_TASK_COUNTS]; in get_recent_times() local
267 memcpy(tasks, groupc->tasks, sizeof(groupc->tasks)); in get_recent_times()
305 reschedule = tasks[NR_RUNNING] + in get_recent_times()
306 tasks[NR_IOWAIT] + in get_recent_times()
307 tasks[NR_MEMSTALL] > 1; in get_recent_times()
783 * assess the aggregate resource states this CPU's tasks in psi_group_change()
812 if (groupc->tasks[t]) { in psi_group_change()
813 groupc->tasks[t]--; in psi_group_change()
815 … printk_deferred(KERN_ERR "psi: task underflow! cpu=%d t=%d tasks=[%u %u %u %u] clear=%x set=%x\n", in psi_group_change()
816 cpu, t, groupc->tasks[0], in psi_group_change()
817 groupc->tasks[1], groupc->tasks[2], in psi_group_change()
818 groupc->tasks[3], clear, set); in psi_group_change()
825 groupc->tasks[t]++; in psi_group_change()
845 if (test_state(groupc->tasks, s, state_mask & PSI_ONCPU)) in psi_group_change()
851 * when there are no other working tasks, but also when in psi_group_change()
981 * any other differences between the two tasks (e.g. prev goes in psi_task_switch()
1196 * stop percpu tasks accounting in each psi_group_cpu, in psi_cgroup_restart()
1205 * to get correct state mask from test_state() loop on tasks[], in psi_cgroup_restart()