Per se, it’s actually not. There are thousands and thousands of hobby-level kernels floating around. Many university courses actually include making your own simple kernel.
The big issue is that the kernel is the core of the whole ecosystem. Everything builds upon it. So if you build a new kernel, you pretty much need to rebuild everything built on top of it.
As a bad comparison, imagine you came up with a genious new shape for a car fuel hose nozzle. You know, the thing you plug into your car to refuel it. Designing a new nozzle is easy. Getting it made isn’t much harder either. Retrofitting billions of cars to work with that new shape is an almost impossible amount of work. So while making a new nozzle is no problem at all, actually implementing it is almost impossible.
The same holds true for the kernel. Making “a kernel” isn’t a big issue. Getting it to work with all PCs with all their diverse hardware and software is close to impossible.
The Linux kernel and the drivers running in it easily have billions of work hours invested into it, and still it doesn’t work perfectly with every piece of hardware you might have in your PC.
Programming is a balance of compromises, one has to define a balance between optimisation, maintainability, legibility, security and much more.
The kernel handles a bunch of different ‘low level’ things that are quite complicated (Allocating memory to programs, scheduling what programs the CPU needs to run, creating security layers for users, handling temperature and performance throttling, peripherals etc)
Due to its pivotal role in an operating system, the kernel developers walk a very thin line of compromises to ensure that it can be maintained and still remain performant.
They do all of this while ensuring that any updates to the Kernel do not break older systems when they update (fingers crossed) or they do not break programs specific to the user (Userspace programs)
Literally everything depends on it. It has to account for a lot of variables. It has to be compatible forward and backward. There’s also a lot of personalities involved in its development and they all need to get along.
What makes the kernel such a PITA?
Per se, it’s actually not. There are thousands and thousands of hobby-level kernels floating around. Many university courses actually include making your own simple kernel.
The big issue is that the kernel is the core of the whole ecosystem. Everything builds upon it. So if you build a new kernel, you pretty much need to rebuild everything built on top of it.
As a bad comparison, imagine you came up with a genious new shape for a car fuel hose nozzle. You know, the thing you plug into your car to refuel it. Designing a new nozzle is easy. Getting it made isn’t much harder either. Retrofitting billions of cars to work with that new shape is an almost impossible amount of work. So while making a new nozzle is no problem at all, actually implementing it is almost impossible.
The same holds true for the kernel. Making “a kernel” isn’t a big issue. Getting it to work with all PCs with all their diverse hardware and software is close to impossible.
The Linux kernel and the drivers running in it easily have billions of work hours invested into it, and still it doesn’t work perfectly with every piece of hardware you might have in your PC.
Programming is a balance of compromises, one has to define a balance between optimisation, maintainability, legibility, security and much more.
The kernel handles a bunch of different ‘low level’ things that are quite complicated (Allocating memory to programs, scheduling what programs the CPU needs to run, creating security layers for users, handling temperature and performance throttling, peripherals etc)
Due to its pivotal role in an operating system, the kernel developers walk a very thin line of compromises to ensure that it can be maintained and still remain performant.
They do all of this while ensuring that any updates to the Kernel do not break older systems when they update (fingers crossed) or they do not break programs specific to the user (Userspace programs)
Literally everything depends on it. It has to account for a lot of variables. It has to be compatible forward and backward. There’s also a lot of personalities involved in its development and they all need to get along.