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

glommio::net::UdpSocket::recv_from is extremely slow #672

Open
bluealert opened this issue Aug 30, 2024 · 4 comments
Open

glommio::net::UdpSocket::recv_from is extremely slow #672

bluealert opened this issue Aug 30, 2024 · 4 comments

Comments

@bluealert
Copy link

test code is here: https://github.com/bluealert/async-udp

run udp_server first:

cargo run --release --bin udp_server
    Finished `release` profile [optimized] target(s) in 0.10s
     Running `target/release/udp_server`
[2024-08-30T10:41:20Z INFO  udp_server] Server is listening on 127.0.0.1:10000

run udp_client:

cargo run --release --bin udp_client
    Finished `release` profile [optimized] target(s) in 0.09s
     Running `target/release/udp_client`
std send: 27us
std recv: 174us

tokio send: 210us
tokio recv: 123us

glommio send: 13us
glommio recv: 14716us

monoio send: 23us
monoio recv: 75us
@bluealert bluealert changed the title glommio::net::UdpSocket::recv_from is exceptionally slow glommio::net::UdpSocket::recv_from is extremely slow Aug 30, 2024
@glommer
Copy link
Collaborator

glommer commented Aug 30, 2024

this is much better on the master branch, made better by commit 2047d3dcbb83bc199600837c0be167f6c0ccab4b
recv is still slower than it should be, but in the ~150us range.

If you can, please point to the git tree in the mean time. I'll take a look on why this is still slower, and release a new version.

@bluealert
Copy link
Author

this is much better on the master branch, made better by commit 2047d3dcbb83bc199600837c0be167f6c0ccab4b recv is still slower than it should be, but in the ~150us range.

If you can, please point to the git tree in the mean time. I'll take a look on why this is still slower, and release a new version.

Thank you!

@bluealert
Copy link
Author

this is much better on the master branch, made better by commit 2047d3dcbb83bc199600837c0be167f6c0ccab4b recv is still slower than it should be, but in the ~150us range.

If you can, please point to the git tree in the mean time. I'll take a look on why this is still slower, and release a new version.

I found glommio/0.8 sometimes very fast

std send: 24us
std recv: 46us

tokio send: 67us
tokio recv: 41us

glommio send: 17us
glommio recv: 3us

monoio send: 17us
monoio recv: 49us

sometimes very slow

std send: 26us
std recv: 67us

tokio send: 61us
tokio recv: 2us

glommio send: 13us
glommio recv: 18290us

monoio send: 16us
monoio recv: 40us

@bluealert
Copy link
Author

bluealert commented Aug 31, 2024

this is much better on the master branch, made better by commit 2047d3dcbb83bc199600837c0be167f6c0ccab4b recv is still slower than it should be, but in the ~150us range.

If you can, please point to the git tree in the mean time. I'll take a look on why this is still slower, and release a new version.

glommio = { git = "https://github.com/DataDog/glommio.git", rev = "d3f6e7a2ee7fb071ada163edcf90fc3286424c31" }

It's ok with above glommio version. Thank you!

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

No branches or pull requests

2 participants