Hyper Fast I/O Event Loop Using io_uring with C++20 Coroutine Support
- liburing
- cmake
sudo apt install cmake
- g++/clang++ with coroutine support
1. mkdir build; cd build
2. cmake -DCMAKE_BUILD_TYPE="Release" -DCMAKE_CXX_COMPILER="/usr/bin/g++-10" ..
OR
cmake -DCMAKE_BUILD_TYPE="Release" -DCMAKE_CXX_COMPILER="/usr/bin/clang++" ..
3. cmake --build .
4. ./echoserver
I am considering releasing documentation but for now example/echoserver.cpp
should be enough
Coroutine example in example/coroutine_echoserver.cpp
Tested on an i7-8650u on WSL (Linux 5.10) using rust_echo_bench
run with cargo run --release -- --address "127.0.0.1:8080"
50 concurrent clients, 512b each: 300,000 reqs/sec
similar performance achieved with example/coroutine_echoserver.cpp
raw performance (IORING_OP_NOP
)
ring size 512 sqes and cqes: 13,300,000 nops/sec
Tested on a Ryzen 7 5800X on Pop OS (Linux 5.8) using rust_echo_bench
run with cargo run --release -- --address "127.0.0.1:8080"
50 concurrent clients, 512b each: 1,100,000 reqs/sec
similar performance achieved with example/coroutine_echoserver.cpp
raw performance (IORING_OP_NOP
)
ring size 512 sqes and cqes: 15,950,000 nops/sec