1.Currently processes in the system are in some kind of list I think(double circular).So what if we assign each process structure (task_struct) property forpriority (maybe already there)and another property which is time how long should run. So insteadhaving ticker in system,each process runs itself predetermined period of time based onpriority and probably few moreparameters that should be in algorithm.

2. Second, when adding process into list, we can have separate sidelists, created in advance (somethinglike slab), where each lists hold tasks of same priority. So when weadd new process to list, at sametime we add it to his priority list. Than scheduler goes trough theselists, based on priority and eachtasks hold it's running time. So we have two points to ease algorithm,lists with single priority and time insideeach process task_struct related to priority.

3. In this way time-granularity of the system is high and allows forreal-time behavior, because we donot have outside time that we "cut" in the middle when interrupthappens, we just interrupt current process and whenfinished, scheduler continue to walk trough lists of processes thatrun its own time.

regards

On Thu, Oct 28, 2010 at 2:26 AM, Christoph Lameter <cl@linux.com> wrote:> On Tue, 26 Oct 2010, Martin Nybo Andersen wrote:>>> On Tue, 26 Oct 2010, Dragoslav Zaric wrote:>>>> > [...]>> >>> > Is it at all possible to implement kernel without ticking, spin system>> > by events and periods ?>>>> You can compile with CONFIG_NO_HZ=n if you want a ticking kernel.>> The kernel always ticks when a process is running CONFIG_NO_HZ does> nothing for that.>>> > Maybe ticking is still best solution to have fast responding system ?>> I think we need a tickless kernel.... Yes....>>> My guesses are that it has already been benchmarked for speed, but you can>> still test it yourself.>> At least power usage/battery times is much better with a tickless kernel.>> Well yes CONFIG_NO_HZ really should say CONFIG_NO_HZ_IDLE. You have> no ticks when a cpu is idle. Otherwise we are ticking...>>