diff options
author | Eric Dumazet <eric.dumazet@gmail.com> | 2011-06-08 09:35:34 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2011-06-08 20:05:30 -0400 |
commit | 4b9d9be839fdb7dcd7ce7619a623fd9015a50cda (patch) | |
tree | bd1827203efe27578b783c30b0ff5e2d4966b26a /Documentation/networking | |
parent | 9ad7c049f0f79c418e293b1b68cf10d68f54fcdb (diff) |
inetpeer: remove unused list
Andi Kleen and Tim Chen reported huge contention on inetpeer
unused_peers.lock, on memcached workload on a 40 core machine, with
disabled route cache.
It appears we constantly flip peers refcnt between 0 and 1 values, and
we must insert/remove peers from unused_peers.list, holding a contended
spinlock.
Remove this list completely and perform a garbage collection on-the-fly,
at lookup time, using the expired nodes we met during the tree
traversal.
This removes a lot of code, makes locking more standard, and obsoletes
two sysctls (inet_peer_gc_mintime and inet_peer_gc_maxtime). This also
removes two pointers in inet_peer structure.
There is still a false sharing effect because refcnt is in first cache
line of object [were the links and keys used by lookups are located], we
might move it at the end of inet_peer structure to let this first cache
line mostly read by cpus.
Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
CC: Andi Kleen <andi@firstfloor.org>
CC: Tim Chen <tim.c.chen@linux.intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'Documentation/networking')
-rw-r--r-- | Documentation/networking/ip-sysctl.txt | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/Documentation/networking/ip-sysctl.txt b/Documentation/networking/ip-sysctl.txt index d3d653a5f9b9..3dcb26cd33f6 100644 --- a/Documentation/networking/ip-sysctl.txt +++ b/Documentation/networking/ip-sysctl.txt | |||
@@ -106,16 +106,6 @@ inet_peer_maxttl - INTEGER | |||
106 | when the number of entries in the pool is very small). | 106 | when the number of entries in the pool is very small). |
107 | Measured in seconds. | 107 | Measured in seconds. |
108 | 108 | ||
109 | inet_peer_gc_mintime - INTEGER | ||
110 | Minimum interval between garbage collection passes. This interval is | ||
111 | in effect under high memory pressure on the pool. | ||
112 | Measured in seconds. | ||
113 | |||
114 | inet_peer_gc_maxtime - INTEGER | ||
115 | Minimum interval between garbage collection passes. This interval is | ||
116 | in effect under low (or absent) memory pressure on the pool. | ||
117 | Measured in seconds. | ||
118 | |||
119 | TCP variables: | 109 | TCP variables: |
120 | 110 | ||
121 | somaxconn - INTEGER | 111 | somaxconn - INTEGER |