Giampaolo Rodola' <g.rod...@gmail.com> added the comment: >> I've a few ideas how to add 0-copy support to protocols.
> I'd be interesting to hear about them. The main challenge IMHO is to find a > way to allow a readinto()-like functionality. Exposing sendfile() should be straightforward. I started implementing it years ago but I gave up pretty soon because asyncio had no solid test framework for testing an actual data transfer between two sockets and that basically represented a blocker. Basically back then all recv() / send() related tests were mocks. Not sure about the current situation but if that has changed I would be happy to contribute a PR (I was the one who contributed socket.sendfile()). As for a readinto()-like functionality: the only thing I'm aware of is splice() syscall but it's Linux only. It must be noted that also sendfile() is UNIX only. Windows achieve the same via TransmitFile. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue31970> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com