|
|
Subscribe / Log in / New account

Patching until the COWs come home (part 1)

Patching until the COWs come home (part 1)

Posted Mar 23, 2021 10:06 UTC (Tue) by pbonzini (subscriber, #60935)
In reply to: Patching until the COWs come home (part 1) by Sesse
Parent article: Patching until the COWs come home (part 1)

Based on a quick Debian Code Search query:

* The fio benchmarking tool supports it

* openssl uses it with AF_ALG (which is also a bit on the obscure side), and so does libkcapi (a library for the kernel crypto API)

* VLC is an interesting one, it uses vmsplice to dump the decompressed output of gzip/bzip2/xz into memory (probably because the rest of the program prefers to work with memory-mapped buffers?)

* FUSE also uses it

Also, Samba doesn't use vmsplice but it uses splice to implement the opposite of sendfile (read from a socket into a file).


to post comments

Patching until the COWs come home (part 1)

Posted Mar 23, 2021 21:49 UTC (Tue) by dgc (subscriber, #6611) [Link] (1 responses)

Yup, vmsplice is the classic "solution looking for a problem to solve" interface.

FWIW, given the well known documented caveats around combining Direct IO, mmap buffers and fork to avoid data corruption and "undefined results" (see open(2) man page) because of interactions COW, I'm also not at all surprised that there are very similar issues resulting from vmsplice() taking temporary unaccounted references to user mapped pages...

-Dave.

Patching until the COWs come home (part 1)

Posted Mar 23, 2021 22:45 UTC (Tue) by pbonzini (subscriber, #60935) [Link]

On the other hand vmsplice is just a handy shortcut. AIO or any use of g_u_p() can cause the same issues.


Copyright © 2025, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds