> > > I could imagine that databases use mmap() havily > > > > it's a little mystery for me why they would do that since it's slower (or > > ought to be), > > slower compared to what? I'd expect the biggest slowdown for > read()/write() be not the price of a syscall, but what you > pay for copying data in/out of the kernel. With mmap() there's > no copying.
as you've pointed out, performance-wise it's not copying vs. nothing it's copying vs page faults and trips through the vm code. i would think playing vm games (as linus likes to say) would make scheduling on mp harder - erik