iproute2/testsuite
Anton Aksola e29a8e0537 iproute2: build nsid-name cache only for commands that need it
The calling of netns_map_init() before command parsing introduced
a performance issue with large number of namespaces.

As commands such as add, del and exec do not need to iterate through
/var/run/netns it would be good not no build the cache before executing
these commands.

Example:
unpatched:
time seq 1 1000 | xargs -n 1 ip netns add

real    0m16.832s
user    0m1.350s
sys    0m15.029s

patched:
time seq 1 1000 | xargs -n 1 ip netns add

real    0m3.859s
user    0m0.132s
sys    0m3.205s

Signed-off-by: Anton Aksola <aakso@iki.fi>
Acked-by: Nicolas Dichtel <nicolas.dichtel@6wind.com>
2016-10-09 18:56:47 -07:00
..
configs Import patch iproute2.112 2005-01-17 23:27:05 +00:00
iproute2 New files in testsuite update (damn CVS) 2005-06-23 20:31:37 +00:00
lib tests: Add output testing 2015-06-24 23:37:26 -04:00
tests iproute2: build nsid-name cache only for commands that need it 2016-10-09 18:56:47 -07:00
Makefile tests: Add output testing 2015-06-24 23:37:26 -04:00