does madvise() have effect on mmap-ed regions?

Mikhail Teterin mi+mx at aldan.algebra.com
Sat Nov 19 00:37:56 GMT 2005


Would something like `fgrep --mmap' benefit from madvise-ing the kernel, that 
the mmap-ed region (the input file) will be used sequentionally 
(MADV_SEQUENTIONAL) and covering the already searched parts with 
MADV_DONTNEED|MADV_FREE?

Thanks!

	-mi


More information about the freebsd-questions mailing list