Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

backend/epoll: implement eventfd wakeup notification #128

Open
wants to merge 8 commits into
base: main
Choose a base branch
from

Conversation

steeve
Copy link

@steeve steeve commented Nov 19, 2024

Tries to mimic what happens in backend/kqueue.

Closes #4

@steeve
Copy link
Author

steeve commented Nov 19, 2024

Added note, without this, trying to use any thread scheduled operation (like file io) will be very slow (up to 100ms).

@steeve
Copy link
Author

steeve commented Jan 7, 2025

gentle ping @mitchellh

@steeve steeve force-pushed the steeve/epoll_eventfd branch 2 times, most recently from 476a87a to 5bc3ad9 Compare January 17, 2025 21:10
mitchellh and others added 8 commits January 17, 2025 22:34
This reverts commit dbe2291, reversing
changes made to 43c7e4b.
When there is more than 256 events, the `events` slice could overflow
when processing completions.
Tries to mimic what happens in backend/kqueue.

Closes mitchellh#4
Since eventfd is now implemented.
Close might block, so dispatch it inside a threadpool.
If an immediate action is dispatched, the loop might block
on epoll_wait even though only one action was requested.
@steeve steeve force-pushed the steeve/epoll_eventfd branch from 5bc3ad9 to 003416b Compare January 17, 2025 21:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

eventfd for wakeup notifications for epoll
4 participants