D and i/o

sarn sarn at theartofmachinery.com
Mon Nov 11 01:04:49 UTC 2019

On Sunday, 10 November 2019 at 20:33:35 UTC, Jonathan Marler 
> For "cat" I believe there is a system call to tell the kernel 
> to forward data from one file descriptor to the other, meaning 
> you could implement cat without ever mapping the data into 
> user-space at all. I'm sure this would be the fastest mechanism 
> to implement cat, and I've seen this system call used by a 
> version of cat somewhere out there.

FTR, that sounds like Linux's sendfile and splice syscalls.  
They're not portable, though.

More information about the Digitalmars-d mailing list