|
|
About ::
TODO ::
Blog ::
RSS ::
Old blog ::
Projects ::
GIT ::
Gallery ::
Notes
Wed, 05 Apr 2006
Netlink performance testing.
For those of you who do not know if it is needed or not to switch
to/from netlink, I've created simple set of benchmarks which shows
performance of _blocking_ data transfer from kernelspace to userspace
in case of using unicast and broadcast.
There are several tests for different number of listening users (1, 2,
4 and 10) and different message size (128, 512, 1024 and 4096 bytes).
10k messages are transferred from process' context (keventd) in one
loop. For unicasting this number of messages is multiplied by number of listening
users, so each user receives 10k messages.
Messages are sent using blocking technique, since otherwise socket
queue with default length of 200k is filled before the first rescheduling,
so it is not allowed to send a lot of events without rescheduling using
nonblocking methods (netlink_broadcast() for example).
While unicast easily allows blocking send, broadcast does not,
so I created simple patch to implement this
functionality, which is only usefull for testing, since netlink table
is locked during test. Performance testing module and userspace tool are
available in archive.
Test was run on 2.4 Ghz Xeon (HT enabled) with 1Gb RAM with 2.6.15-rc6
kernel.

From this test one can see, that unicasting is faster for 1 and maybe 2
users, and broadcast definitely wins when number of users increases.
:: Link / Comments ()
|