MCPcopy Create free account
hub / github.com/F-Stack/f-stack / sched_lowest

Function sched_lowest

freebsd/kern/sched_ule.c:805–818  ·  view source on GitHub ↗

* Find the cpu with the least load via the least loaded path that has a * lowpri greater than pri pri. A pri of -1 indicates any priority is * acceptable. */

Source from the content-addressed store, hash-verified

803 * acceptable.
804 */
805static inline int
806sched_lowest(const struct cpu_group *cg, cpuset_t mask, int pri, int maxload,
807 int prefer)
808{
809 struct cpu_search low;
810
811 low.cs_cpu = -1;
812 low.cs_prefer = prefer;
813 low.cs_mask = mask;
814 low.cs_pri = pri;
815 low.cs_limit = maxload;
816 cpu_search_lowest(cg, &low);
817 return low.cs_cpu;
818}
819
820/*
821 * Find the cpu with the highest load via the highest loaded path.

Callers 2

sched_balance_groupFunction · 0.85
sched_pickcpuFunction · 0.85

Calls 1

cpu_search_lowestFunction · 0.85

Tested by

no test coverage detected