summaryrefslogtreecommitdiff
path: root/Kernel/Scheduler.h
AgeCommit message (Collapse)Author
2019-07-22Move runnable/non-runnable list control entirely over to SchedulerRobin Burchell
This way, we can change how the scheduler works without having to change Thread too.
2019-07-03AK: Rename the common integer typedefs to make it obvious what they are.Andreas Kling
These types can be picked up by including <AK/Types.h>: * u8, u16, u32, u64 (unsigned) * i8, i16, i32, i64 (signed)
2019-05-28Add clang-format fileRobin Burchell
Also run it across the whole tree to get everything using the One True Style. We don't yet run this in an automated fashion as it's a little slow, but there is a snippet to do so in makeall.sh.
2019-05-15Kernel: Add a beep() syscall that beeps the PC speaker.Andreas Kling
Hook this up in Terminal so that the '\a' character generates a beep. Finally emit an '\a' character in the shell line editing code when backspacing at the start of the line.
2019-04-14Kernel: Remove system.h and make the uptime global a qword.Andreas Kling
2019-03-23Kernel: Introduce threads, and refactor everything in support of it.Andreas Kling
The scheduler now operates on threads, rather than on processes. Each process has a main thread, and can have any number of additional threads. The process exits when the main thread exits. This patch doesn't actually spawn any additional threads, it merely does all the plumbing needed to make it possible. :^)
2019-02-07Kernel: When a lock is busy, donate remaining process ticks to lock holder.Andreas Kling
Since we know who's holding the lock, and we're gonna have to yield anyway, we can just ask the scheduler to donate any remaining ticks to that process.
2019-02-06Kernel: Add a Finalizer process to take care of dying processes.Andreas Kling
Instead of processes themselves getting scheduled to finish dying, let's have a Finalizer process that wakes up whenever someone is dying. This way we can do all kinds of lock-taking in process cleanup without risking reentering the scheduler.
2019-02-06Kernel: Clean up around Scheduler::yield() a bit.Andreas Kling
Also add assertion in Lock that the scheduler isn't currently active. I've been seeing occasional fuckups that I suspect might be someone called by the scheduler trying to take a busy lock.
2019-02-04Add a /bin/top program for process table monitoring.Andreas Kling
It automagically computes %CPU usage based on the number of times a process has been scheduled between samples. The colonel task is used as idle timer. This is pretty cool. :^)
2019-01-25Kernel: Implement lazy FPU state restore.Andreas Kling
2018-11-08Move timer tick handling into Scheduler.Andreas Kling
2018-11-07Get rid of the undertaker and have waitpid() be the reaper.Andreas Kling
For dead orphans, the scheduler calls reap().
2018-11-07Move the scheduler code to its own class.Andreas Kling
This is very mechanical.