Alexey Dobriyan
9b130ad5bb
treewide: make "nr_cpu_ids" unsigned
...
First, number of CPUs can't be negative number.
Second, different signnnedness leads to suboptimal code in the following
cases:
1)
kmalloc(nr_cpu_ids * sizeof(X));
"int" has to be sign extended to size_t.
2)
while (loff_t *pos < nr_cpu_ids)
MOVSXD is 1 byte longed than the same MOV.
Other cases exist as well. Basically compiler is told that nr_cpu_ids
can't be negative which can't be deduced if it is "int".
Code savings on allyesconfig kernel: -3KB
add/remove: 0/0 grow/shrink: 25/264 up/down: 261/-3631 (-3370)
function old new delta
coretemp_cpu_online 450 512 +62
rcu_init_one 1234 1272 +38
pci_device_probe 374 399 +25
...
pgdat_reclaimable_pages 628 556 -72
select_fallback_rq 446 369 -77
task_numa_find_cpu 1923 1807 -116
Link: http://lkml.kernel.org/r/20170819114959.GA30580@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:48 -07:00
..
2017-08-10 12:20:53 +02:00
2017-04-20 12:09:55 -06:00
2017-09-08 18:26:46 -07:00
2017-02-22 16:41:29 -08:00
2017-06-05 16:59:12 +02:00
2017-08-18 15:32:02 -07:00
2017-07-10 16:32:32 -07:00
2017-04-18 20:41:12 +02:00
2017-07-06 16:24:32 -07:00
2016-03-17 15:09:34 -07:00
2017-08-10 15:54:07 -07:00
2017-02-27 18:43:47 -08:00
2017-07-18 11:38:02 +02:00
2017-09-08 18:26:47 -07:00
2016-03-15 16:55:16 -07:00
2017-09-06 20:49:49 -07:00
2017-05-08 17:15:13 -07:00
2016-07-26 16:19:19 -07:00
2017-09-08 18:26:46 -07:00
2016-05-19 19:12:14 -07:00
2017-09-08 18:26:46 -07:00
2017-09-08 18:26:45 -07:00
2016-05-20 17:58:30 -07:00
2017-09-07 10:15:40 -07:00
2017-05-03 15:52:12 -07:00
2016-11-22 11:49:48 -06:00
2017-09-06 17:27:30 -07:00
2017-09-08 18:26:46 -07:00
2017-05-03 15:52:10 -07:00
2017-07-10 16:32:31 -07:00
2017-04-18 11:42:36 -07:00
2016-03-17 15:09:34 -07:00
2017-07-06 16:24:34 -07:00
2017-09-06 17:27:27 -07:00
2017-07-10 16:32:33 -07:00
2016-05-22 17:21:27 -07:00
2017-09-08 18:26:46 -07:00
2017-09-08 18:26:46 -07:00
2017-08-25 16:12:46 -07:00
2017-09-08 18:26:47 -07:00
2017-09-08 18:26:46 -07:00
2017-08-17 10:30:49 +02:00
2017-09-08 18:26:47 -07:00
2017-09-08 18:26:47 -07:00
2017-06-20 12:18:27 +02:00
2017-09-08 18:26:46 -07:00
2017-02-24 17:46:56 -08:00
2017-09-08 18:26:47 -07:00
2016-03-17 15:09:34 -07:00
2017-09-06 17:27:30 -07:00
2017-03-02 08:42:38 +01:00
2017-08-31 16:13:00 -07:00
2017-02-22 16:41:29 -08:00
2017-09-08 18:26:46 -07:00
2017-09-08 18:26:45 -07:00
2017-08-18 15:32:01 -07:00
2017-09-06 17:27:29 -07:00
2017-09-06 17:27:30 -07:00
2017-09-08 18:26:47 -07:00
2017-09-06 17:27:26 -07:00
2017-09-06 17:27:27 -07:00
2017-09-07 11:59:42 -07:00
2017-07-10 16:32:31 -07:00
2017-09-06 17:27:26 -07:00
2017-05-03 15:52:10 -07:00
2017-09-08 18:26:46 -07:00
2017-09-06 17:27:29 -07:00
2017-07-06 16:24:34 -07:00
2017-07-26 17:41:05 -04:00
2017-07-26 17:41:05 -04:00
2017-07-26 17:41:05 -04:00
2017-06-29 11:23:38 -04:00
2017-07-26 17:41:06 -04:00
2017-09-08 18:26:45 -07:00
2017-03-02 08:42:28 +01:00
2016-03-17 15:09:34 -07:00
2016-12-12 18:55:08 -08:00
2017-09-08 18:26:46 -07:00
2017-05-03 15:52:09 -07:00
2017-09-06 17:27:29 -07:00
2017-07-06 16:24:31 -07:00
2017-07-06 16:24:35 -07:00
2017-08-10 12:29:03 +02:00
2017-08-10 12:29:03 +02:00
2017-09-08 18:26:48 -07:00
2017-09-06 17:27:26 -07:00
2017-09-08 18:26:47 -07:00
2017-07-06 16:24:31 -07:00
2017-07-10 16:32:32 -07:00
2017-09-06 17:27:29 -07:00
2017-09-08 18:26:46 -07:00
2017-09-08 18:26:47 -07:00
2017-07-10 16:32:32 -07:00
2017-04-05 12:30:18 -07:00
2017-09-06 17:27:28 -07:00
2017-09-06 17:27:29 -07:00
2017-03-02 08:42:38 +01:00
2017-09-06 17:27:29 -07:00
2017-07-10 16:32:31 -07:00
2017-09-06 17:27:28 -07:00
2017-09-08 18:26:47 -07:00
2017-07-06 16:24:35 -07:00
2017-09-06 17:27:30 -07:00
2017-09-08 18:26:47 -07:00
2017-07-06 16:24:35 -07:00