On Tue, Jan 12, 2016 at 04:53:25PM +0200, Boris Astardzhiev wrote: > Hello again, > > In my spare time I did the following simple libc-only implementation of the > syscalls. > I did some tests in a VM adapting these experiments: > https://blog.cloudflare.com/how-to-receive-a-million-packets/ > > Any comments about the diff are greatly appreciated. Please find below.
This implementation has some strangeness, like NOASM and PSEUDO in makefile, which I cannot find a purpose for. Big issue with the implementation is the interposing stuff, why do you need it at all ? Is it to correctly handle cancellation, to not fall into sleepable syscall when previous loop step was cancelled ? If yes, you _can_ use pthread_testcancel(3) etc in libc. Libc provides stubs for them with trivial implementation, which is reset to the real one if libthr is loaded. Then you can simplify your patch significantly, avoiding the need for interposing and writing the loops both in libc and libthr. BTW, do you have tests for the cancellation of the new functions ? Again, the patch lacks man page updates. _______________________________________________ freebsd-net@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/freebsd-net To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"