The second acquaintance with OS Inferno

    When it’s not working, many read bash.org.ru or anekdot.ru ... and this winter I climbed out of boredom to re-read the OS Inferno website . Useful with longing, because although I had long been drawn to Inferno, I expected the practical benefits of reading docks on Inferno as much as from the above sites.

    But something unexpected happened - during the reading process an insight came over me: I realized that OS Inferno is not an operating system, but a development environment !

    Sounds weird? Yes. It’s especially strange when you consider that the first sentence on the Inferno website is “Inferno is a compact operating system ...”. The bottom line is that when the "operating system" is pronounced nowadays, desktop Windows and Linux appear in people's heads, and any other OS starts to be compared with them. In addition to desktop OSs, few will think about server ones. But Inferno does not look sufficient even for the server, I'm already silent about the desktop. Thus, comparing Inferno with Windows and Linux, we come to the conclusion that Inferno is, although adorable, but a "toy" OS. Perhaps in the future, when bash, apache, mysql, perl, vi and mplayer appear in Inferno, it will become more or less usable ... The future has come, last timeI picked Inferno about 5 years ago ... so what? But nothing has changed, Inferno still lacks bash, apache, mysql, perl, vi and mplayer!

    My insight can be described as follows: Inferno is not more like an OS, but a regular service that shares the resources of the computer it is running on to the network using the Styx protocol .

    Yes, this, to put it mildly , is not a completely accurate description of Inferno ... ;-) but it instantly changed EVERYTHING: I stopped discomfort due to the lack of familiar software in Inferno - I can continue to work in Linux using the usual Vim (with syntax highlighting for Limbo !), Bash, mc for developing software for Inferno!

    Moreover, after several days of hard work with Inferno, I generally began to incline to consider Inferno not as an OS, but as ... a programming language! :) For example, you can compare Inferno / Limbo and my favorite Perl. In both cases, I write a program, it is compiled into bytecode, and then executed inside the virtual machine. My program has access to some high-level abstractions, and low-level system calls (syscall). So in both cases, you can implement almost any task, and they will most likely work at a comparable speed (by the way, I conducted several tests that confirmed this). The only major difference is the environment with which my program interacts:
    • Perl provides "more than one way to do it", a lot of high-level things like structural, object-oriented and functional (map, grep, sort, ...) programming styles; scalar variables, lack of type checking and many other things that make programming comfortable.
    • Inferno provides a very simple and elegant environment, hiding from me nightmares of the architecture and implementation of the POSIX / Linux kernel / Glibc. It also provides much more control over the resources used (perl does not just use a lot of memory, it just eats it!), Without forcing me to program at a too low level: call free (), create strings from character arrays with pens, call a function every time I need to compare or copy strings, etc.

    All of these definitions of “what is Inferno” are in fact, of course, not definitions of Inferno - for Inferno is a “compact operating system”. These definitions are simply trying to describe the relationship to Inferno, i.e. not "what is Inferno," but "how to use Inferno." For example, when I start comparing Inferno and Perl, this is because when I need to develop some application I can use either Inferno / Limbo or Linux / Perl. With high probability, the size of the code, the speed of development and execution will be comparable. And when I need to choose the most suitable platform for this task, I will choose between the very rich and flexible Perl on the ugly Linux architecture, or between the not so rich and flexible, but very simple Limbo on the amazing Inferno architecture.

    For example, if you need to write a web page parser, log analyzer, and other word processing applications, Perl is better for these tasks. But if you need something lower level, for example a complex server with asynchronous I / O, then on Inferno / Limbo it will be much easier and more pleasant to write such things.

    As for existing applications in Inferno (browser, for example), then, as I understand it, these are examples of applications, and nothing more. This is just a demonstration of the capabilities of the system, and for demos they are more than impressive!
    Inferno apps

    All in all, Inferno is a tool. The same as, for example, a programming language. And this tool has long been ready for use in real, commercial applications. And, like any tool, for some tasks it is much better than for others. But about that -next time .

    Also popular now: