You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We currently map IPv4 addresses to IPv6 ones, and then work on IPv6 addresses exclusively. This is a significant performance hit, since we need to hash 4x more bytes (roughly).
If we split the code into IPv4 and IPv6 specific, we can determine the protocol in New and then attach the correct BPF filter. This should give us a nice boost for IPv4.
The text was updated successfully, but these errors were encountered:
Then we could use a for loop + #pragma unroll to generate one version for ipv4 and ipv6 each. That would still involve a lot of copypasta, so maybe there is a better solution.
There is an important optimization to be had: since we know the IP
version of a socket we can attach a socket filter that is specialised
to IPv4 or IPv6. This is a big win for IPv4, since we end up hashing
a lot less data.
We also generate less code, so we are closer to not needing a higher
optmem limit for IPv4.
Fixes#2
Updates #13
We currently map IPv4 addresses to IPv6 ones, and then work on IPv6 addresses exclusively. This is a significant performance hit, since we need to hash 4x more bytes (roughly).
If we split the code into IPv4 and IPv6 specific, we can determine the protocol in
New
and then attach the correct BPF filter. This should give us a nice boost for IPv4.The text was updated successfully, but these errors were encountered: