#13 AIO support


Patch to support waiting for AIO operations' completion. User is able to submit multiple AIO requests and wait for their completion using libevent, thus eliminating disk IO waits in asynchronous applications.

Supported platforms: FreeBSD/kqeueue. On other platforms signal notification should work, provided POSIX AIO is available. However the signal notification should be less performant, than AIO with native notification methods.

As an example asynchronous gzipper is implemented (see aio-test.c).

Please look forward for further patches to AIO support.


  • Valery Kholodkov

    File containing the patch

  • Nobody/Anonymous

    It would be great if you have patch for latest releases ?
    which version of the libevent was used to create this patch ?

  • Nobody/Anonymous

    Please integrate this patch!

  • Nobody/Anonymous

    Whats the status with integrating this patch?

  • Nick Mathewson

    Nick Mathewson - 2010-01-15

    Damn; we've left this alone for too long. val_kh: are you interested in making this work with the latest 2.0.x msater? I'm interested in having something like this get applied.

    There are some things I'm not sure about. For instance, why must event.h include aio.h?

    Also, my understanding of AIO was that it supported lots of different operations, not just "read" and "write". Wy do we need specific functions for those?

  • Valery Kholodkov

    Hello Nick!

    Yes, I'm interested in integrating this into your master branch.

    Let's discuss it per mail during this weekend.

  • Valery Kholodkov

    A version of previous patch for libevent 2.0.3-dev-alpha

  • Remi Gacogne

    Remi Gacogne - 2012-02-26


    I was wondering why this feature never made it to the master branch (AFAIK) ? Is there any hope to see something similar one day, or is it a design problem ?

    Thank you,

  • Nick Mathewson

    Nick Mathewson - 2012-02-27

    It's been a while, so this is just from memory, but I think it's Mainly because of the lack of portability and because of the effect it had on other Libevent APIs, and making struct event longer, and so forth.

    I'm not opposed to adding in an AIO hookup for people who want it, but I think it needs a cleaner interface.

    If somebody wants to clean it up, I'll try to take another look at the old patch to try to remember what the issue was.


Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

No, thanks