[PATCH v2] core/coio_file: Use eio_sendfile_sync instead of a chunk mode
Cyrill Gorcunov
gorcunov at gmail.com
Tue Apr 16 20:51:33 MSK 2019
On Tue, Apr 16, 2019 at 08:35:10PM +0300, Vladimir Davydov wrote:
> > - Proper testing of large files remains opened: current CI engine
> > is hardly capable of managing it. I tested 200M files with manual
> > splitting (to make sure the offsets do really work) but for longterm
> > we still might need to invent something
>
> We could use an error injection to reduce the size of data fed to
> sendfile in one go.
I don't remember if I already asked -- mind to point me where our
error injection examples are?
> > - Another question which remains -- what to do with partially copied
> > files, neither code before the patch or after do not clean up parts
> > of copied data. Should not we clean it up on error path? If yes then
> > I'll prepare another patch on top.
>
> Nobody complained => I don't think we need to do anything about it.
ok
> > + for (left = st.st_size, pos = 0; left > 0;) {
>
> st.st_size has time off_t while left has type ssize_t. They differ on
> 32-bit machines AFAIR.
Well, not exactly. It depends on __USE_FILE_OFFSET64 definition
but true, better to be on a safe side and use off_t type instead.
Thanks, will update!
More information about the Tarantool-patches
mailing list