Giter Site home page Giter Site logo

ysingh / io_uring-by-example Goto Github PK

View Code? Open in Web Editor NEW

This project forked from shuveb/io_uring-by-example

0.0 0.0 0.0 81 KB

A companion repository for the io_uring by Example article series

License: MIT License

C 97.26% Makefile 1.17% HTML 1.57%

io_uring-by-example's Introduction

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 io_uring API.
  • 02_cat_uring: This example builds a version of cat with the raw interface provided by io_uring. This is done so that the user understands how the io_uring interface works at a low-level.
  • 03_cat_liburing: This example is functionally the same as the previous example, but uses the higher-level API provided by liburing.
  • 04_cp_liburing: This example is an implementation of a copy command that uses multiple requests in io_uring'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

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.