Linux Zero-Copy: Transfer memory pages between two processes with vmsplice

独自空忆成欢 提交于 2019-12-02 22:25:57
dtatulea

As R.. mentioned, you only need to pass the fd to the receiving process somehow and on the other side use it as a normal fd.

edit: Actually, you have to use vmsplice() on the sending side to map the buffer to the pipe and splice() on the receiving side on the other end of the pipe. See an example here.

Another choice would be to use a shared mmap-ing.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!