LoseJoe wrote: ↑
Tue Jan 02, 2018 7:18 pm
Hello, i am a developer, i code a bunch of discord bots, and i am experienced with node.js, i was wondering about creating an operating system in node.js for myself, if i cannot code with node.js for an OS, could you please give me suggestions for coding languages that are like node.js, i also need some forums, or anything you can do to try to help me get started. Thanks!
Whether you can code an operating system using node.js depends on what you mean by an operating system. The closest thing to a full operating system that I've seen so far written in node.js has been a reimplementation of MudOs
. More information can be found on the lpmud.net forum
Many times I've wanted to implement my own operating system in order to make something that was simple enough to be correct. The closest I managed was a multi-threading library and some bare-metal device drivers written for very old hardware in a mixture of Turbo Pascal and x86 assembler. If I were to try again, I would take the approach that Google took with Android and simply create a new user land on top of the Linux kernel. Google wrote much of Android using Java and it might be possible to use node.js to do something similar.
At this point in time the Linux kernel is well parallelized, but the usual GNU user land is not. If I were creating a new user land for Linux, I would choose a programming language designed for parallel processing and use parallel algorithms whenever possible, because 8 or more cores are now available in low-end commodity hardware. Reasonable choices of languages for parallel processing include golang, rust, Cilkplus or C99 with OpenMP. Unfortunately, none of these languages are beautiful enough in my opinion to make a compelling case for writing a new user land using one of them.