From: Eric Wong Date: 2017-09-05T10:52:15+00:00 Subject: [ruby-core:82652] Re: [Ruby trunk Feature#13867] Copy offloading in IO.copy_stream glass.saga@gmail.com wrote: > In linux 4.5, the copy offloading feature with copy_file_range(2) was introduced. > This patch enables IO.copy_stream to use it. Cool. > If "offload" keyword argument is specified, IO.copy_stream will try copy offloading. Is a new keyword arg necessary? Since this is Linux-only, and we already do fstat tests on both FDs in the sendfile checking: We can try using copy_file_range if both src and dst are both regular files with identical .st_dev, and fall back to using sendfile on ENOSYS. Thanks. Unsubscribe: