-
Notifications
You must be signed in to change notification settings - Fork 71
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use Iomux.Poll.ppoll instead of epoll via ocaml-poll
An Iomux.Poll.t holds has an entry for each available file descriptor. The allocation strategy is straightforward: - Each index in the poll array maps to the fd of same number. - We toggle the poll slot activation when we move from waiters->empty and empty->waiters. This is a bit different than before as we actually call `update` after `iter_ready` unregistering the possible interest. - We have to bump maxi everytime we go over the current allocated, and we don't go back, we could decrement maxi when we close the last one, but we can't really avoid holes, so don't bother. I'm surprised this worked the first time, I still have to review it.
- Loading branch information
Showing
2 changed files
with
49 additions
and
42 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters