4 ms·
> A main driver of performance for network drivers is sending/receiving packets in batches from/to the NIC. Ixy can already achieve a high performance with rela
by usaphp 8y ago
> A main driver of performance for network drivers is sending/receiving packets in batches from/to the NIC. Ixy can already achieve a high performance with relatively low batch sizes of 32-64 because it is a full user space driver. Other user space packet processing frameworks like netmap that rely on a kernel driver need larger batch sizes of 512 and above to amortize the larger overhead of communicating with the driver in the kernel.
- mpweiher 8y agoInteresting! As our devices have gotten faster, the user-space/kernel boundary is becoming more and more of an issue. I was shocked when my supposedly super-fast MacBook Pro SSD (2+GB/s) was only giving me around 250MB/s. Turned out mkfile(8), which I was using without thinking much about it, is only using 512 byte buffers... https://blog.metaobject.com/2017/02/mkfile8-is-severely-syscall-limited-on.html https://blog.metaobject.com/2017/02/mkfile8-is-severely-sysc...
- zozbot123 8y agoThe main thing affecting performance at the userspace/kernel boundary these days is Spectre and Meltdown mitigations, FWIW...
- mpweiher 8y agoYeah, when I ran the same tests a little later and with the Spectre/Meltdown patches (+APFS, which also didn't help), the mkfile I/O rate had a further precipitous drop to ~80MB/s.
- vlovich123 8y agoNo, userspace/kernel transitions are always and will always be slow. Every time it happens you've got to do a context switch which is super-expensive + cache unfriendly. You also pay a penalty keeping the kernel mapped at all times in terms of more pressure on the TLB but due to Spectre and Meltdown mitigations the kernel has actually been unmapped hurting the performance of switching into kernel further although this will be undone eventually.