I like operating systems and would eventually like to become a OS developer mostly working on kernels. In the future will C still be the language of choice and what else should I be trying to learn?
相关问题
- Why should we check WIFEXITED after wait in order
- Linux kernel behaviour on heap overrun or stack ov
- Where is the standard kernel libraries to let kern
- Is there a difference between an ISR and an interr
- Trouble with SPIDEV, device tree and .dtbo name wi
相关文章
- How do I get to see DbgPrint output from my kernel
- What happens to dynamic allocated memory when call
- Is it possible to run 16 bit code in an operating
- How to arrange a Makefile to compile a kernel modu
- Tool to Debug Guest OS in Virtual Box
- How can the linux bottom halfs execute in interrup
- Linux Kernel Linked List
- How is copy paste possible?
I've done extensive programming in both the Windows NT and Linux Kernel. And I can assure you that as long as these 2 OS's are around C will be used in the Kernel. I think it's a multitude of reasons, but the easiest answer is time. Like previous posters mentioned the amount of time it would take to rewrite the Kernel in a different language is not worth it. And it wouldn't just be porting the code. The kernel would need some serious design modifications. Personally I think C is the most suitable language for a Kernel. Being able to manage your open memory and dynamically allocate and free your own memory is crucial when you are working in the kernel. Especially if you are working with paged memory. The stack size you are allotted in Kernel mode is also generally smaller than user mode so again memory efficiency is crucial. C also allows programmers to build beautiful data structures that don't contain all the bloated overhead that managed languages have. In my opinion a struct can also be used just as effectively as an Object, but again without all the bloated overhead. Managed languages also need to be "managed." In the Kernel you don't have anything cleaning up your messes. Don't get me wrong, I love C# and I think the .NET framework is beautiful, but if you are in the kernel C is and will continue to be it.
You might want to have a look at the Singularity project from Microsoft (also on Wikipedia):
Only an extremely small part of this OS is actually written in C, and the rest is written in higher level languages (Sing#, an extension of C#). In the future I believe you can expect to see much more of this kind of thing becoming available.
If it is kernel you are talking about, then you need to learn a language that will enable easy access to the underlying hardware, faster. I can only think of
AFAIK, some parts of the boot-loader will be written in assembly, and from then on, C. There are many open-source easy-to-understand operating systems available, like for example the latest TOPPERS. Try to look into it.
I guess, as a OS-kernel developer, you will worry more about the ways to efficiently access underlying hardware (like processor and memory) rather than the choice of the language. I bet, most of the times, we will be tempted to use assembly
well, in the osdev community C is generally called the high-level language. And the more "low-level" language would be assembly (you are forced to use ASM in the start of your kernel, so you have to use ASM but you don't have to use C).
I think it's safe to say that low-level parts of operating systems (e.g. the kernel) will continue to be written in C because of its speed. Like mentioned elsewhere, you will need to know assembler for certain parts of the kernel (something needs to load the kernel into memory). But you can work on the kernel with little or no assembly knowledge. A good example would be if you're implementing a file system.
Don't worry about what language the operating system is implemented in. What's important is how an operating systems are used, and what can be done to improve them. A good example is when Unix first came out. The file system had the inodes at the front of the disk, and data in the remaining space. This didn't perform very well as you were seeking to different parts of the disk for all files. Then the Berkeley Fast File System was created to make a disk aware file system. This means having inodes near their corresponding data. I'm leaving out a lot of details, but I hope this illustrates that it's more important to think about how an operating system can be improved rather than what language it will be programmed in.
Some recent trends in operating systems are virtualization and distributed computing (see Google's paper on MapReduce). File systems, security, scheduling (especially with multi-core processors), etc are continually areas of interest even though these problems are not new.
Here are some resources if you want to learn more about kernel development:
Bottom line: Start getting familiar with the kernel and read papers on what researchers are writing about (USENIX is useful for this). This knowledge is much more valuable than learning a new language, as most concepts from one language can easily be transferred to another if there does happen to be a shift in what operating systems are written. Hope this helps!