7

The Linux kernel is often listed as a code base which you are recommended to read and, even if it is poorly commented (or the files I have looked at have all been), it does have some really good code in it.

Now, putting the Linux kernel aside, which other operating system kernels do you recommend people interested in systems programming and/or operating systems to study? Why? What is so great about the code base? Would it show you very different approaches from what the Linux kernel has gone with? Do they use interesting technologies? Something else...?

That the kernels are under an open source license is more or less necessary.

Anto
  • 11,197

4 Answers4

10

A great kernel is MINIX 3 deeply explained in the Tanenbaum's book (exist in paperback): Operating Systems Design and Implementation.

...Written by the creator of Minux, professional programmers will now have the most up-to-date tutorial and reference available today.

Revised to address the latest version of MINIX (MINIX 3), this streamlined, simplified new edition remains the only operating systems text to first explain relevant principles, then demonstrate their applications using a Unix-like operating system as a detailed example. It has been especially designed for high reliability, for use in embedded systems, and for ease of teaching...

gnat
  • 20,543
  • 29
  • 115
  • 306
BenjaminB
  • 1,706
6

Microsoft Research Singularity. A very different approach to designing an Operating System. Based on advances in modern programming languages, type systems, tools, static analysis, compilers and program verification. In fact, the majority of the team didn't even come from Microsoft Research's Operating System Division, they were language, tool, verification and compiler people.

The basic idea is that static typing and analysis can give much stronger guarantees about process isolation than the CPU's MMU can. And it can give these guarantees at compile time instead of runtime, which means that processes are much more lightweight. Lightweight enough, in fact, that every device driver, every file system, every subcomponent of an application, can run in its own, isolated, garbage collected, process with practically zero overhead. (A context switch is pretty much just flipping a bunch of pointers. There is no checking involved, since all of that has already been done at compile time.)

The ideas in Singularity are carried forward in some other operating systems out of MSR: Midori (which is rumored to be a commercial implementation of Singularity and a possible successor to Windows NT) and Helios (which takes the idea of having all device drivers, OS services and programs written in a hardware-independent language and applies it to a multi-kernel approach, where different parts of the OS run on different CPUs with possibly different ISAs).

Jörg W Mittag
  • 104,619
6

Inferno -- worth checking out, because many of it's ideas sooner or later get 'backported' to Linux/Unix. It's an experimental operating system by Bell Labs, and continuation of their work on Plan9.

Most interesting feature of Inferno is how it makes network resources completely transparent to applications:

Transparent Resources

Inferno offers complete transparency of resources and data using a simple but powerful 'namespace' system. By representing resources as files and having one standard communication protocol — 9P (Styx®) — resources such as data stores, services and external devices can easily be shared between Inferno systems. A resource interface may be imported to the local system and used by the applications without them knowing, or needing to know, whether it is local or remote.

vartec
  • 20,846
5

Oberon. The books are The Oberon System: User Guide and Programmer's Manual and Project Oberon: The Design of an Operating System and Compiler

Oberon is an existence proof of the assertion that big workstation operating systems don't have to be big. At a time when Unix required many megabytes just to load (and one of the early Linux distros wouldn't load in less than 8 megabytes), Oberon provided a complete workstation operating system with a memory footprint about 300 kbytes.