Performance optimization in av::fixup - use buffered IO, not mapped file

Corinna Vinschen
Thu Dec 13 19:21:00 GMT 2012

On Dec 13 11:02, Daniel Colascione wrote:
> On 12/13/12 2:39 AM, Corinna Vinschen wrote:
> > On Dec 13 01:44, Daniel Colascione wrote:
> >> What about using the automatic sparse handling in lseek/lwrite and
> >> ftruncate only when the file being operated on is already sparse?
> > 
> > That doesn't make sense.  If the file is already sparse, there's no
> > reason to set the sparse flag in write or ftruncate again.  Also, if you
> > set the sparse flag only on already sparse files, you will never be able
> > to create sparse 
> Yes, you're right. I thought I remembered a separate call we could
> have retained to actually punch a hole in a sparse file.

That's what Eric mentioned yesterday.  The Linux-specific fallocate call
can do that, but this isn't implemented in Cygwin yet(*).



Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Project Co-Leader          cygwin AT cygwin DOT com
Red Hat

More information about the Cygwin-developers mailing list