Hacker News new | ask | show | jobs
by micahcc 899 days ago
> a simple multi-processor round robin (SMP)

> the kernel is very small and does not block, so does not need to be preemptible

I don't believe you and I don't even need to look at the code to know this is false.

1 comments

Care to elaborate?
From the docs at the top of scheduler.rs

    // The scheduler.
    //
    // As the kernel supports wait/wake/swap, and no blocking in the kernel
    // other than wait, any kind of more sophisticated scheduling policy
    // can be implemented in the userspace (in theory; maybe tweaks are needed
    // to make things perform well in practive).
    //
    // So the default scheduler here is rather simple, but should work
    // for a lot of use cases.
    //
    // Priorities: see enum Priority
    // Cpu affinity: a single CPU hint
    // Sched groups: none: everything within a priority is round robin, so
    // a process with many threads will negatively affect a process with few threads.
    //
    // This should be OK for most situations: if there is a need for isolation,
    // just use another VM.
That's elaboration enough I think?