Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Limit on kevent entries?



On Thu, 12 Oct 2006, maurits wrote:
OK, I'd highly appreciate any input. Portability is not an issue for me. But
I have the feeling that kevents doesn't really scale too well, and I agree with you that I'm probably abusing the mechanism...

In general kqueues do scale well, and that's part of the purpose of them. We use them to multiplex I/O over many thousands of sockets. I haven't pushed them terribly hard on Darwin (just enough to hit some bugs in older versions) but I have no reason to believe they shouldn't scale well there too, relative to Darwin's level of low level performance in general.

cool, that's good to hear. I guess I didn't mean that kqueues don't scale well (in fact they do, it seems), but I'm just not sure how good it is to crank up the number of open files to really large numbers. However, I've now used setrlimit() to set it up to 5000, and my machine is still alive, and the code works just great now. Guess I can live with a limit in that region.


P.S. if you continue to use kqueue, make sure you open the files with O_EVTONLY, if you aren't already.

d'uh. Good point. I used O_RDONLY...

Thanks again for the great help,

Moritz
--
http://www.plasticsfuture.org
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/darwin-dev/email@hidden

This email sent to email@hidden


Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.