inlining click: +10%
Robert Morris
rtm at cag.lcs.mit.edu
Sun Apr 23 19:31:05 EDT 2000
If I take the output of click-devirtualize and cause g++ to inline it,
it gets about 10% faster. I first outlined some of the element code,
and also got rid of some (more) old hand-optimizations that got rid of
virtual function calls. So every element has a simple_action.
My benchmark is the following IP-like configuration, running at user
level:
e12 :: Discard;
e11 :: IPFragmenter(1500);
e10 :: DecIPTTL;
e9 :: FixIPSrc(2.0.0.1);
e8 :: IPGWOptions(2.0.0.1);
e7 :: CheckPaint(2);
e6 :: DropBroadcasts;
e5 :: GetIPAddress(16);
e4 :: CheckIPHeader();
e3 :: Strip(14);
e2 :: Paint(1);
e1 :: InfiniteSource(\<00 00 c0 ae 67 ef 00 00 00 00 00 00 08 00
45 00 00 28 00 00 00 00 40 11 77 c3 01 00 00 01
02 00 00 02 13 69 13 69 00 14 d6 41 55 44 50 20
70 61 63 6b 65 74 21 0a 04 00 00 00 01 00 00 00
01 00 00 00 00 00 00 00 00 80 04 08 00 80 04 08
53 53 00 00 53 53 00 00 05 00 00 00 00 10 00 00
01 00 00 00 54 53 00 00 54 e3 04 08 54 e3 04 08
d8 01 00 00>, 1000000, 5);
e1 -> e2
-> e3
-> e4
-> e5
-> e6
-> e7
-> e8
-> e9
-> e10
-> e11
-> e12;
e7[1] -> Discard;
More information about the click
mailing list