Giter VIP home page Giter VIP logo

kbio's Introduction

kbio's People

Contributors

alexcrichton avatar asomers avatar aturon avatar bdonlan avatar blasrodri avatar carllerche avatar cssivision avatar darksonn avatar davidpdrsn avatar dekellum avatar doumanash avatar hawkw avatar ipetkov avatar jonhoo avatar juleskers avatar kleimkuhler avatar kpp avatar luciofranco avatar marwes avatar mikailbag avatar nylonicious avatar oberien avatar radicalzephyr avatar seanmonstar avatar sfackler avatar taiki-e avatar udoprog avatar vorner avatar vorot93 avatar zaharidichev avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

isgasho my3157

kbio's Issues

Remove the polling when there is no free slot

Curently we will keep polling when there is no free slot.

if let Some(slot) = future.uring.submit(sqe) {
    // ...
} else {
    // There is no free slot.
    // We expect that wake_by_ref() will put the task at tail of task queue.
    // But Tokio will put the task at "next task" slot, so it will run again immediately.
    cx.waker().wake_by_ref();
    return Poll::Pending;
}

I am working to remove the polling. I will save the waker in the free list when there is no slot, and invoke waker.wake() when others release the slot.

Integration with Tokio

After thinking about it, it's not a good practice to use kbio alone. In this case, Walker.Wake() occurs in kbio's own thread, and it needs a cross thread communication to submit task to Tokio runtime.

It is better to directly replace Tokio IO::driver from Mio to io-uring, in this way, IO tasks are directly submitted to the current thread. Iouring and wake() will also occur on the same thread. At this time, cross thread thread communication will generally only occur in the case of work steal.

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.