nmh-workers
[Top][All Lists]
Advanced

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

Re: [Nmh-workers] m_getfld


From: Ralph Corderoy
Subject: Re: [Nmh-workers] m_getfld
Date: Wed, 12 Dec 2012 00:54:07 +0000

Hi David,

> Would it make sense to toss it all and use mmap()?  Conceptually, it
> doesn't seem like a difficult problem to parse header fields and maybe
> a body and just hand back a pair of pointers and the state indication.

I'd be -1.  It doesn't seem like it's worth deviating from the file I/O
model for any performance gain mmap(2) may give on the platforms that
support it.  On the downside, it'll be less familiar to some and POSIX
leaves what happens if the file changes and then a new or deleted bit is
accessed as `unspecified' IIRC.  mmap seems fine if the program is
accessing files under its sole control, perhaps not such a good fit for
nmh.  At least with file I/O we wouldn't suffer signals.

Cheers, Ralph.



reply via email to

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