Eric Dumazet
ce27ec6064
net: add high_order_alloc_disable sysctl/static key
...
>From linux-3.7, (commit 5640f76858 "net: use a per task frag
allocator") TCP sendmsg() has preferred using order-3 allocations.
While it gives good results for most cases, we had reports
that heavy uses of TCP over loopback were hitting a spinlock
contention in page allocations/freeing.
This commits adds a sysctl so that admins can opt-in
for order-0 allocations. Hopefully mm layer might optimize
order-3 allocations in the future since it could give us
a nice boost (see 8 lines of following benchmark)
The following benchmark shows a win when more than 8 TCP_STREAM
threads are running (56 x86 cores server in my tests)
for thr in {1..30}
do
sysctl -wq net.core.high_order_alloc_disable=0
T0=`./super_netperf $thr -H 127.0.0.1 -l 15`
sysctl -wq net.core.high_order_alloc_disable=1
T1=`./super_netperf $thr -H 127.0.0.1 -l 15`
echo $thr:$T0:$T1
done
1: 49979: 37267
2: 98745: 76286
3: 141088: 110051
4: 177414: 144772
5: 197587: 173563
6: 215377: 208448
7: 241061: 234087
8: 267155: 263373
9: 295069: 297402
10: 312393: 335213
11: 340462: 368778
12: 371366: 403954
13: 412344: 443713
14: 426617: 473580
15: 474418: 507861
16: 503261: 538539
17: 522331: 563096
18: 532409: 567084
19: 550824: 605240
20: 525493: 641988
21: 564574: 665843
22: 567349: 690868
23: 583846: 710917
24: 588715: 736306
25: 603212: 763494
26: 604083: 792654
27: 602241: 796450
28: 604291: 797993
29: 611610: 833249
30: 577356: 841062
Signed-off-by: Eric Dumazet <edumazet@google.com >
Signed-off-by: David S. Miller <davem@davemloft.net >
2019-06-14 20:18:28 -07:00
..
2019-05-30 11:29:21 -07:00
2019-05-05 19:29:04 +02:00
2019-05-30 11:29:22 -07:00
2018-09-26 09:56:07 -07:00
2019-05-21 16:10:38 +02:00
2019-04-30 14:18:56 +02:00
2019-05-21 11:28:45 +02:00
2019-02-21 16:23:56 -08:00
2019-05-24 17:39:00 +02:00
2019-05-30 11:29:52 -07:00
2017-04-12 22:02:36 +02:00
2019-03-21 13:26:42 -07:00
2019-06-12 11:00:11 -07:00
2019-05-30 11:26:41 -07:00
2019-05-30 11:26:32 -07:00
2019-02-28 08:24:23 -07:00
2018-08-07 12:39:13 -07:00
2017-11-02 11:10:55 +01:00
2019-05-05 11:25:49 -07:00
2017-11-02 11:10:55 +01:00
2019-01-23 11:18:00 -08:00
2018-04-19 16:11:11 -04:00
2019-05-24 17:37:53 +02:00
2019-05-21 11:28:40 +02:00
2019-05-30 11:26:32 -07:00
2018-09-26 20:22:19 -07:00
2019-04-27 09:07:04 -07:00
2018-07-30 09:10:25 -07:00
2019-05-21 11:28:45 +02:00
2019-05-24 11:26:54 +02:00
2019-05-30 11:26:41 -07:00
2019-05-30 11:26:32 -07:00
2019-05-21 11:28:45 +02:00
2019-05-30 11:26:32 -07:00
2019-04-19 14:07:40 -07:00
2017-11-02 11:10:55 +01:00
2019-05-30 11:29:52 -07:00
2019-05-30 11:29:52 -07:00
2019-05-30 11:26:32 -07:00
2017-11-02 11:10:55 +01:00
2017-11-02 11:10:55 +01:00
2017-11-02 11:10:55 +01:00
2019-05-21 11:52:39 +02:00
2019-05-21 11:52:39 +02:00
2017-11-04 09:26:51 +09:00
2019-05-30 11:26:32 -07:00
2017-11-02 11:10:55 +01:00
2018-03-05 12:52:45 -05:00
2017-11-04 09:26:51 +09:00
2017-11-02 11:10:55 +01:00
2019-03-21 13:39:25 -07:00
2018-05-20 18:31:42 -04:00
2017-11-02 11:10:55 +01:00
2018-02-28 11:43:28 -05:00
2018-05-28 22:59:54 -04:00
2019-04-22 21:50:53 -07:00
2018-04-23 10:21:24 -04:00
2017-11-02 11:10:55 +01:00
2019-06-12 10:09:56 -07:00
2019-05-16 12:02:42 -07:00
2019-02-27 12:50:17 -08:00
2017-11-02 11:10:55 +01:00
2019-04-26 13:02:11 +02:00
2017-10-11 09:49:34 +02:00
2017-11-02 11:10:55 +01:00
2018-11-17 21:37:29 -08:00
2019-04-27 17:07:22 -04:00
2019-03-22 12:09:31 -07:00
2018-12-10 15:53:04 -08:00
2017-11-02 11:10:55 +01:00
2017-11-02 11:10:55 +01:00
2017-12-11 14:10:06 -05:00
2017-11-02 11:10:55 +01:00
2019-05-30 11:26:32 -07:00
2019-02-22 12:56:24 -08:00
2019-05-30 11:26:41 -07:00
2019-05-30 11:26:32 -07:00
2019-04-22 21:50:53 -07:00
2019-05-30 11:26:32 -07:00
2019-05-30 11:26:32 -07:00
2019-05-30 11:26:32 -07:00
2018-12-15 13:23:02 -08:00
2019-05-30 11:26:32 -07:00
2018-10-17 17:45:07 -07:00
2019-02-26 08:27:05 -08:00
2019-05-30 11:26:32 -07:00
2019-05-30 11:26:32 -07:00
2019-05-30 11:26:32 -07:00
2019-02-08 21:50:15 -08:00
2019-05-30 11:26:32 -07:00
2019-06-07 09:29:14 -07:00
2019-04-23 19:44:18 -07:00
2018-11-08 17:13:08 -08:00
2019-05-30 11:26:32 -07:00
2019-02-27 12:50:17 -08:00
2019-04-08 22:57:59 +02:00
2019-05-30 11:26:32 -07:00
2017-11-02 11:10:55 +01:00
2017-11-02 11:10:55 +01:00
2019-05-05 10:40:24 -07:00
2019-04-17 23:10:47 -07:00
2019-05-30 11:26:32 -07:00
2017-11-02 11:10:55 +01:00
2018-03-27 09:51:23 +02:00
2019-05-30 11:26:32 -07:00
2018-07-11 23:10:19 -07:00
2017-11-02 11:10:55 +01:00
2017-11-02 11:10:55 +01:00
2017-10-25 12:06:25 +09:00
2018-04-22 14:55:03 -04:00
2018-09-13 09:04:58 -07:00
2019-04-23 19:42:29 -07:00
2019-04-26 16:05:52 -04:00
2019-05-30 11:26:41 -07:00
2019-05-21 11:28:45 +02:00
2017-11-02 11:10:55 +01:00
2017-04-01 20:21:44 -07:00
2016-10-03 02:00:22 -04:00
2017-11-02 11:10:55 +01:00
2017-11-02 11:10:55 +01:00
2019-04-08 15:22:40 -07:00
2019-04-17 23:19:07 -07:00
2018-05-28 22:59:54 -04:00
2019-03-28 17:00:45 -07:00
2017-11-02 11:10:55 +01:00
2018-08-01 09:52:30 -07:00
2019-05-21 11:28:45 +02:00
2019-05-04 01:27:11 -04:00
2019-05-30 11:26:32 -07:00
2019-04-11 13:59:49 -07:00
2017-11-08 16:12:33 +09:00
2017-11-02 11:10:55 +01:00
2018-05-24 18:36:15 -07:00
2019-05-30 11:26:32 -07:00
2019-05-07 12:23:40 -07:00
2018-09-25 20:17:35 -07:00
2017-11-02 11:10:55 +01:00
2019-05-30 11:26:32 -07:00
2019-04-22 21:50:53 -07:00
2017-11-02 11:10:55 +01:00
2019-05-30 11:26:32 -07:00
2017-11-02 11:10:55 +01:00
2017-12-05 14:37:13 -05:00
2018-08-28 11:11:47 +02:00
2019-05-30 11:26:32 -07:00
2018-05-16 07:23:35 +02:00
2019-05-30 11:26:32 -07:00
2018-03-13 18:37:02 +02:00
2018-11-06 15:00:45 -08:00
2019-04-22 21:47:25 -07:00
2019-04-23 18:36:33 +02:00
2018-07-21 10:43:12 -05:00
2017-11-02 11:10:55 +01:00
2019-05-30 11:26:32 -07:00
2019-05-30 11:26:32 -07:00
2019-05-30 11:26:32 -07:00
2018-04-11 10:33:46 -04:00
2019-02-21 10:34:37 -08:00
2019-05-30 11:26:32 -07:00
2018-08-11 01:58:46 +02:00
2019-06-14 20:18:28 -07:00
2018-03-01 21:21:36 -05:00
2017-11-02 11:10:55 +01:00
2018-06-06 14:07:53 -04:00
2019-05-30 11:26:32 -07:00
2019-05-30 11:26:32 -07:00
2019-05-30 11:26:32 -07:00
2019-05-30 11:26:32 -07:00
2018-05-08 00:02:41 -04:00
2019-06-04 13:34:37 -07:00
2018-07-07 10:58:49 +09:00
2017-11-02 11:10:55 +01:00
2017-08-29 15:16:52 -07:00
2019-03-29 10:53:45 -07:00
2019-05-31 08:34:32 -07:00
2018-02-16 15:57:42 -05:00
2019-03-22 12:09:31 -07:00
2018-01-24 19:13:45 -05:00
2017-11-02 11:10:55 +01:00
2017-11-02 11:10:55 +01:00
2019-03-16 01:27:51 +01:00
2018-08-29 12:25:53 -07:00
2019-05-07 22:03:58 -07:00