diff options
author | kib <kib@FreeBSD.org> | 2014-07-10 09:08:02 +0000 |
---|---|---|
committer | kib <kib@FreeBSD.org> | 2014-07-10 09:08:02 +0000 |
commit | eb437edaac20126d793a49220709d14049745797 (patch) | |
tree | 5af84c2c6223836c6b1221f9708931c1ea3de833 | |
parent | eda5b267ec30385810e19d396265222d6c7692cc (diff) | |
download | FreeBSD-src-eb437edaac20126d793a49220709d14049745797.zip FreeBSD-src-eb437edaac20126d793a49220709d14049745797.tar.gz |
MFC r268211:
Micro-manage clang to get the expected inlining for cpu_search().
-rw-r--r-- | sys/kern/sched_ule.c | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/sys/kern/sched_ule.c b/sys/kern/sched_ule.c index e897310..f4df381 100644 --- a/sys/kern/sched_ule.c +++ b/sys/kern/sched_ule.c @@ -622,12 +622,14 @@ struct cpu_search { for ((cpu) = 0; (cpu) <= mp_maxid; (cpu)++) \ if (CPU_ISSET(cpu, &mask)) -static __inline int cpu_search(const struct cpu_group *cg, struct cpu_search *low, - struct cpu_search *high, const int match); -int cpu_search_lowest(const struct cpu_group *cg, struct cpu_search *low); -int cpu_search_highest(const struct cpu_group *cg, struct cpu_search *high); -int cpu_search_both(const struct cpu_group *cg, struct cpu_search *low, +static __always_inline int cpu_search(const struct cpu_group *cg, + struct cpu_search *low, struct cpu_search *high, const int match); +int __noinline cpu_search_lowest(const struct cpu_group *cg, + struct cpu_search *low); +int __noinline cpu_search_highest(const struct cpu_group *cg, struct cpu_search *high); +int __noinline cpu_search_both(const struct cpu_group *cg, + struct cpu_search *low, struct cpu_search *high); /* * Search the tree of cpu_groups for the lowest or highest loaded cpu @@ -640,7 +642,7 @@ int cpu_search_both(const struct cpu_group *cg, struct cpu_search *low, * match argument. It is reduced to the minimum set for each case. It is * also recursive to the depth of the tree. */ -static __inline int +static __always_inline int cpu_search(const struct cpu_group *cg, struct cpu_search *low, struct cpu_search *high, const int match) { |