-
Notifications
You must be signed in to change notification settings - Fork 7
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
Can we use fixed buffers for UringSocket
?
#55
Comments
I created a simple C program and experimented it, and it seems possible to read and write sockets using fixed_buffer apis such as If my understanding is correct, fixed buffers are associated with |
@mox692 nice job, that's great! Are there
Yes, I believe that's right. But I think we need to decide how many buffers we want and how big they should be so that we can pre-allocate them. Maybe that's okay, but I felt a bit unsure about it, particularly for services that expects to have lots of connections. |
Ah, I missed that point. The program I used for the experiment was using the _fixed version of read/write, not recv/send. (my very rough example here ) But, now I look at the liburing implementation, it seems that io_uring_prep_read_fixed and io_uring_prep_readv are based on the same function io_uring_prep_rw, so if we done properly, it seems possible to perform socket read/write with flags set like recv/send.
yeah, I also don't have a clear answer for this part..
I will consider these topics a bit more. |
Related discussion, I think? |
https://unixism.net/loti/tutorial/fixed_buffers.html
The text was updated successfully, but these errors were encountered: