bug-tar
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Bug-tar] Use posix_fadvise to improve archive creation performance


From: Ralph Corderoy
Subject: Re: [Bug-tar] Use posix_fadvise to improve archive creation performance
Date: Thu, 30 Mar 2017 19:34:11 +0100

Hi Paul,

> > I think it would be a good idea to add an option to tell tar whether
> > to use POSIX_FADV_NOREUSE, POSIX_FADV_DONTNEED, or neither, since
> > there may be cases where any of the three possibilities is best.
>
> Might make sense, yes.

I often want to run tar, sha1sum, grep, etc., on a huge file knowing
that I won't do it again soon and I don't want it bullying the nice
working-set cache out the door.  It seems crazy every command has to add
options to twiddle POSIX_FADV_NOREUSE, like dd(1)'s nocache [io]flag
IIRC.  We have stdbuf(1).  Perhaps a similar approach can be used to
affect command, even if it can't work in all cases.

    fadvise --noreuse sha1sum big.foo

(Linux not implementing it aside.  Perhaps wider use in userspace would
encourage implementation.)

-- 
Cheers, Ralph.
https://plus.google.com/+RalphCorderoy



reply via email to

[Prev in Thread] Current Thread [Next in Thread]