Admin message

Due to a large amount of spam we do not allow new users to create repositories, they are "external" users. If you are a new user and want to create a repository, for example for forking GHC, open a new issue on ghc/ghc using the "get-verified" issue template

Need new select() based I/O manager
We're trying to remove the old select() I/O manager (which has many quirks), and ideally we would not rely on select() at all, see #22588. The plan had been that the new `poll()` I/O manager would be the replacement, serving as a portable (but not quick) I/O manager. And then we would be able to retire the old select implementation (see !11700). The best laid schemes o’ mice an’ men. Unfortunately we discovered that `poll()` is not usable on macOS https://gitlab.haskell.org/ghc/ghc/-/merge_requests/9677#note_625290: > So `poll()` is borked on OSX, and documented as such: https://developer.apple.com/library/archive/documentation/System/Conceptual/ManPages_iPhoneOS/man2/poll.2.html > > > BUGS The poll() system call currently does not support devices. > > Yes really. > > Other projects have run into this too apparently. In `glib` they have a `g_poll()` emulated on top of `select()` and they use that on `BROKEN_POLL` platforms, which includes OSX. The irony is that older versions of OSX implemented `poll` as an emulation on top of `select` (which presumably thus worked), and then later in adding a native implementation they borked it. Sigh. > > So that explains why test T7773 fails. That test opens `/dev/random/` (a character device) and does a `threadWaitRead` (which calls into the I/O manager, and thus `poll()`). > > This makes this I/O manager unusable on OSX. This is kind of a shame since it means we cannot retire the old `select()` I/O manager (see #22588 and !11700), and we will need to either: add a new `select()` I/O manager (based on the new infrastructure) or add a `kqueue` one that's good enough to be used by default with no fallback. The kqueue I/O manager is promising, but still pending, see !12848. In the meantime, it would still be nice to deprecate the classic select I/O manager, and copying the structure of new poll I/O manager and tweaking it to use `select()` is not that hard. Indeed I've already done it in !16359. And in all honesty, this ticket is just here to justify the MR I already wrote :stuck_out_tongue:.
issue