:> :Poul-Henning Kamp | UNIX since Zilog Zeus 3.20
:> :[EMAIL PROTECTED] | TCP/IP since RFC 956
:>
:> I think the file descriptor problem can be solved easily... simply
:> open the file, mmap() the entire 1G segment for this special application,
:> and then close() the file. Then have sbrk() just eats out of the mapped
:> segment. Alternatively sbrk() could open/mmap/close in large 1MB or 4MB
:> segments, again leaving no file descriptors dangling.
:
:Won't that cause fragmentation? You're forgettng the need to
:ftruncate or pre-zero the file unless that's been fixed.
:
:--
:-Alfred Perlstein [[EMAIL PROTECTED]]
You have to pre-zero the file. You can do it in reasonably-sized
chunks (like 4M) without causing fragmentation. You *CANNOT* use
ftruncate() to extend the file - that will virtually guarentee massive
fragmentation.
-Matt
To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message