Need help with io_uring-by-example?
Click the “chat” button below for chat support from the developer who created it, or find similar developers for support.

About the developer

shuveb
139 Stars 21 Forks MIT License 19 Commits 0 Opened issues

Description

A companion repository for the io_uring by Example article series

Services available

!
?

Need anything else?

Contributors list

# 309,786
C
HTML
9 commits
# 137,339
TypeScr...
HTML
Shell
service...
1 commit
# 246,057
Git
Shell
industr...
JavaScr...
1 commit
# 27,899
emacs-l...
elisp
zsh-com...
lean
1 commit
# 15,665
Haskell
Bash
node
Markdow...
1 commit
# 141,097
c-plus-...
cpp17
luajit
pe-form...
1 commit

io_uring By Example

This repository is a companion repo for the article series io_uring By Example on the Unixism blog.

It features a set of example programs that serve as an example to illustrate the usage of Linux's io_uring subsystem. The examples build one on top of the other, becoming progressively complex.

Here are what the examples do: -

01_regular_cat
: This is an example of a "cat" program equivalent that uses regular, synchronous I/O. This program is there to illustrate the difference between synchronous I/O and the asynchronous iouring API. - `02caturing`: This example builds a version of cat with the raw interface provided by iouring. This is done so that the user understands how the iouring interface works at a low-level. - `03catliburing
: This example is functionally the same as the previous example, but uses the higher-level API provided by liburing.
-
04
cpliburing`: This example is an implementation of a copy command that uses multiple requests in iouring's submission queue. -
05_webserver_liburing
: This is the final example in the series. This bulids a simple web server that is capable of serving static files. It illustrates the use of
accept()
, along with
readv()
and
writev()
.

Please note that you will need at least Linux kernel version 5.5 and above to get all these examples to work. Support for the

accept()
operation in io_uring was added in kernel v5.5.

The example web server in action

Zerohttpd

We use cookies. If you continue to browse the site, you agree to the use of cookies. For more information on our use of cookies please see our Privacy Policy.