Alexey Dobriyan
f22ef333c3
cpumask: make cpumask_next() out-of-line
...
Every for_each_XXX_cpu() invocation calls cpumask_next() which is an
inline function:
static inline unsigned int cpumask_next(int n, const struct cpumask *srcp)
{
/* -1 is a legal arg here. */
if (n != -1)
cpumask_check(n);
return find_next_bit(cpumask_bits(srcp), nr_cpumask_bits, n + 1);
}
However!
find_next_bit() is regular out-of-line function which means "nr_cpu_ids"
load and increment happen at the caller resulting in a lot of bloat
x86_64 defconfig:
add/remove: 3/0 grow/shrink: 8/373 up/down: 155/-5668 (-5513)
x86_64 allyesconfig-ish:
add/remove: 3/1 grow/shrink: 57/634 up/down: 3515/-28177 (-24662) !!!
Some archs redefine find_next_bit() but it is OK:
m68k inline but SMP is not supported
arm out-of-line
unicore32 out-of-line
Function call will happen anyway, so move load and increment into callee.
Link: http://lkml.kernel.org/r/20170824230010.GA1593@avx2
Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2017-09-08 18:26:51 -07:00
..
2016-03-17 21:38:27 -07:00
2017-02-27 18:43:46 -08:00
2017-02-24 17:46:57 -08:00
2014-09-28 11:08:01 +02:00
2017-08-22 14:53:32 +08:00
2017-09-07 12:41:48 -07:00
2014-06-04 16:54:18 -07:00
2015-09-10 13:29:01 -07:00
2017-05-08 17:15:12 -07:00
2016-05-17 09:33:39 -07:00
2017-08-30 16:40:11 -06:00
2017-07-14 15:05:13 -07:00
locking/atomic: Implement atomic{,64,_long}_fetch_{add,sub,and,andnot,or,xor}{,_relaxed,_acquire,_release}()
2016-06-16 10:48:32 +02:00
2014-12-13 12:42:51 -08:00
2017-09-08 18:26:49 -07:00
2014-12-22 16:43:06 +00:00
2017-07-10 16:32:35 -07:00
2015-11-23 09:44:58 +01:00
2017-03-30 09:37:20 +02:00
2016-07-03 00:57:23 -04:00
2016-03-13 23:55:13 -04:00
2014-04-03 16:21:12 -07:00
2017-09-08 18:26:49 -07:00
2014-03-20 10:11:35 -04:00
2015-05-27 15:22:15 +02:00
2017-09-08 18:26:51 -07:00
2017-06-09 11:52:07 +02:00
2014-05-16 14:26:52 -04:00
2017-02-24 17:46:57 -08:00
2017-02-24 17:46:57 -08:00
2015-05-26 15:26:43 +02:00
2015-05-30 22:42:24 -07:00
2015-06-11 15:08:32 +02:00
2017-08-14 16:51:01 +02:00
2015-09-10 13:29:01 -07:00
2015-09-10 13:29:01 -07:00
2017-02-24 17:46:57 -08:00
2015-09-10 13:29:01 -07:00
2015-09-10 13:29:01 -07:00
2015-09-10 13:29:01 -07:00
2015-07-17 16:39:54 -07:00
2017-04-24 13:53:13 -05:00
2017-03-02 10:09:00 +11:00
2015-11-16 14:42:12 -05:00
2017-05-09 15:40:28 -07:00
2017-06-28 06:55:01 -07:00
2017-06-28 06:54:41 -07:00
2017-03-02 08:42:34 +01:00
2016-08-04 08:50:07 -04:00
2015-02-12 18:54:15 -08:00
2016-06-08 11:04:19 +02:00
2017-07-26 12:24:36 -04:00
2017-07-10 16:32:35 -07:00
2017-08-10 15:54:06 -07:00
2014-04-30 19:49:37 +01:00
2017-02-24 17:46:57 -08:00
2014-01-21 23:17:20 -08:00
2017-06-20 15:42:32 -04:00
2016-05-20 17:58:30 -07:00
2015-02-13 21:21:35 -08:00
2016-10-27 18:43:43 -07:00
2017-02-24 17:46:57 -08:00
2017-02-24 17:46:57 -08:00
2017-09-08 18:26:49 -07:00
2016-06-08 15:01:02 +02:00
2017-08-30 14:36:44 -07:00
2017-09-08 18:26:49 -07:00
2015-02-12 18:54:15 -08:00
2016-01-20 17:09:18 -08:00
2014-04-07 16:36:11 -07:00
2015-11-05 16:34:48 -08:00
2016-08-02 19:35:07 -04:00
2017-03-09 11:48:47 -08:00
2017-07-07 20:39:20 -07:00
2016-10-15 10:03:15 -07:00
2017-03-02 08:42:38 +01:00
2016-01-16 11:17:27 -08:00
2017-09-08 18:26:48 -07:00
2017-09-08 18:26:49 -07:00
2016-07-28 16:07:41 -07:00
2017-05-16 08:44:22 -03:00
2016-12-14 16:04:08 -08:00
2014-08-08 15:57:25 -07:00
2016-02-07 22:18:47 -08:00
2017-07-22 12:00:15 +02:00
2017-03-22 20:11:35 -06:00
2017-07-10 16:32:34 -07:00
2015-03-31 09:45:50 -06:00
2017-06-08 17:36:03 +08:00
2017-02-24 17:46:56 -08:00
2017-05-08 17:15:10 -07:00
2015-11-06 17:50:42 -08:00
2017-06-08 10:35:50 +02:00
2017-08-29 15:15:17 +02:00
2016-11-16 10:15:10 +01:00
2015-11-25 09:22:02 -07:00
2017-09-08 18:26:49 -07:00
2014-06-25 17:45:43 -07:00
2015-12-03 11:49:23 -05:00
2017-09-03 17:08:42 -07:00
2017-05-19 14:42:19 +02:00
2016-05-19 19:12:14 -07:00
2017-09-08 18:26:49 -07:00
2015-10-08 05:26:36 -07:00
2017-02-03 16:35:42 -05:00
2016-12-06 10:17:03 +02:00
2015-09-08 14:35:59 -07:00
2017-07-12 16:26:05 -07:00
2017-03-02 08:42:34 +01:00
2017-03-22 19:18:43 -07:00
2017-03-02 08:42:27 +01:00
2017-01-23 09:17:12 +01:00
2017-09-08 18:26:49 -07:00
2016-10-15 10:03:15 -07:00
2016-08-02 19:35:06 -04:00
2017-09-08 18:26:48 -07:00
2017-09-08 18:26:48 -07:00
2014-01-21 23:17:20 -08:00
2017-06-28 18:54:46 +02:00
2017-07-15 12:44:02 -07:00
2017-04-14 14:06:52 -06:00
2017-06-15 14:30:14 +02:00
2015-12-23 14:27:20 -05:00
2016-04-15 16:53:14 -04:00
2015-08-24 14:28:01 -06:00
2015-03-23 22:12:08 -04:00
2017-02-22 16:41:30 -08:00
2017-01-09 13:58:57 -05:00
2017-05-23 10:01:38 +02:00
2017-02-24 17:46:57 -08:00
2016-11-11 08:12:37 -08:00
2015-02-12 18:54:16 -08:00
2016-04-21 10:47:26 +10:00
2017-09-08 18:26:49 -07:00
2016-10-11 15:06:30 -07:00
2017-05-15 23:40:22 -04:00
2017-07-18 11:38:03 +02:00
2017-03-24 07:43:35 +01:00
2017-09-08 18:26:49 -07:00
2017-08-09 16:53:56 -07:00
2017-09-08 18:26:49 -07:00
2017-08-10 13:58:41 -07:00
2016-09-01 17:52:01 -07:00
2016-01-20 17:09:18 -08:00
2017-03-31 17:13:30 -07:00
2017-09-08 18:26:50 -07:00
2017-05-08 17:15:10 -07:00
2014-01-23 16:36:57 -08:00
2017-02-26 11:03:38 -05:00
2016-03-15 16:55:16 -07:00
2017-07-25 12:35:23 -07:00
2017-01-09 13:58:57 -05:00
2017-05-08 17:15:10 -07:00
2015-08-03 11:51:12 +02:00
2016-02-09 10:27:29 +01:00
2017-07-12 16:26:00 -07:00
2017-05-01 09:36:30 +02:00
2017-07-21 09:38:30 +02:00
2015-09-10 13:29:01 -07:00
2016-02-03 08:28:43 -08:00
2014-10-14 02:18:14 +02:00
2017-01-20 08:03:42 +01:00
2016-08-02 17:31:41 -04:00
2016-01-20 17:09:18 -08:00
2016-09-09 16:08:46 +01:00
2017-06-29 22:21:20 -04:00
2017-06-05 16:59:05 +02:00
2017-07-07 10:37:54 -07:00
2016-09-21 00:22:59 -04:00