Skip to content

Conversation

@Berrysoft
Copy link
Member

@Berrysoft Berrysoft commented Sep 22, 2023

@George-Miao you've always want this:)

However I've found some problems:

  • The key of Event is said to identify the fd, I don't know whether an fd could be registered with multiple different keys.
  • Don't know if it is allowed to add one fd several times with different keys.

Bonus: Closes #67

@Berrysoft Berrysoft marked this pull request as draft September 22, 2023 04:39
@George-Miao
Copy link
Member

Cool! Also this should bring more platforms into supported list of compio.

@Berrysoft Berrysoft added help wanted Extra attention is needed driver: polling About the polling driver labels Sep 22, 2023
@Berrysoft
Copy link
Member Author

Well there's a big problem here: if one fd added with different keys, it will only show up once. That means we cannot perform multiple read operations on one file.

@Berrysoft Berrysoft removed the help wanted Extra attention is needed label Sep 22, 2023
@Berrysoft Berrysoft marked this pull request as ready for review September 22, 2023 09:42
@Berrysoft
Copy link
Member Author

I have to maintain a queue myself to control the interest.

@Berrysoft
Copy link
Member Author

The performance will be poor if one fd registers a lot operations. We can only pop one operation each time.

I have a question: when a fd is readable, how many read operation could we perform? What if it is writable?

@George-Miao

@Berrysoft Berrysoft merged commit 22afe2f into master Sep 22, 2023
@Berrysoft Berrysoft deleted the dev/polling2 branch September 22, 2023 10:55
@George-Miao
Copy link
Member

I have a question: when a fd is readable, how many read operation could we perform? What if it is writable?

@George-Miao

It really depends on what type of fd is. I think most of the time it only means at most one read/write operation is non blocking.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

driver: polling About the polling driver

Projects

None yet

Development

Successfully merging this pull request may close these issues.

mio driver doesn't support multiple submission of one fd

3 participants