我要创建一个操作系统,但我不知道应该使用哪种编程语言? [英] I am going ro create a Operating System, but I don`t know which Programming languages I should use?

查看:84
本文介绍了我要创建一个操作系统,但我不知道应该使用哪种编程语言?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我打算创建一个操作系统,但我不知道应该使用哪种编程语言?

我完全清楚创建操作系统需要做多少工作,但我认为这很有趣。

但是我应该使用哪种编程语言?谢谢: - )

Hi, I am going to create a Operating System, but I don`t know which Programming languages I should use?
I am fully aware how much work it takes to create a OS, but I think it will be fun.
But yeah Which programming languages should I use? Thanks:-)

推荐答案

正如 Dave Kreskowiak 已经指出的那样, C 汇编是用于开发操作系统的最常用的编程语言。如果您的目标是PC,我建议您阅读 ox3c0 的精彩文章系列:开始操作系统开发 [ ^ ](at至少要了解所需的努力。)
As Dave Kreskowiak already pointed out, C and Assembly are the most used programming languages for developing operating systems. If your target is a PC, I suggest you to read the great article series of ox3c0: "Beginning Operating System Development"[^] (at least to get an idea about the required effort).


如果你不得不问这个问题你不知道你要进入什么。



到目前为止,汇编程序和C是最常见的。如果你确实知道你进入了什么,你就会知道为什么选择它们以及在哪里使用它们。
If you have to ask this question you don't know what you're getting into.

Assembler and C are the most common, by far. If you did know what you were getting into, you'd know why these are picked and where to use them.


首先要做的是开始查看你要去的环境运行,以及可用的编译器或交叉编译器。然后你可以开始研究如何使用它们,因为许多基本的库函数(例如从用户那里获取一个字符和打印此字符串)使用操作系统函数来执行它...



这不是一项简单的任务:您可能希望使用多种语言组合:汇编程序(速度和紧凑性),C表示更高级别可读性而不会失去太多的速度,并且可能是C ++以获得更高级别的抽象(在操作系统的整个生命周期中需要进行大多数修改),这有助于提高可读性和可维护性。



你真的不能使用的语言包括Javascript,VB和C#!



但我真的不认为你理解这涉及多少工作。有一本好书值得一读: http:// www.amazon.com/Developing-32-Bit-Operating-System-Cd-Rom/dp/0672306557 [ ^ ] - 但这些天它有点基础,它不会让你运行Windows 10克隆圣诞节!也许是DOS克隆,如果你真的花费时间和精力......
The first thing to do is start looking at the environment you are going to run in, and the compilers or cross compilers that are available. And then you can start looking at how you are going to use them, given that many basic library functions (such as "get a character from the user" and "print this string") use operating system functions to do it...

This is not a simple task: the chances are that you will want to use a combination of languages: assembler (for the speed and compactness), C for the higher level readability without losing too much speed, and probably C++ to get the higher level abstractions (that will need the most modifications over the life of the OS) that aid readability and maintainability.

Languages you really can't use include Javascript, VB, and C#!

But I don't really think you understand how much work this involves. There is a good book which will be well worth reading: http://www.amazon.com/Developing-32-Bit-Operating-System-Cd-Rom/dp/0672306557[^] - but it's a bit basic these days, and it won't get you running with a Windows 10 clone by Christmas! Maybe a DOS clone, if you really put the time and effort in...


这篇关于我要创建一个操作系统,但我不知道应该使用哪种编程语言?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆