7 ms·
Still makes no sense to me to spend energy into pushing Rust into Linux instead of creating some new better kernels, I mean having some of this big companies pa
by simion314 5y ago
Still makes no sense to me to spend energy into pushing Rust into Linux instead of creating some new better kernels, I mean having some of this big companies paying a few experts to do such a kernel and keep compatibility with user applications. If Rust is much better then C and adding on top the fact you start fresh with no baggage you should get a better Linux and everyone would use it since is safer and faster especially on servers.
I don't know of such a Rust kernel being worked on that is not some hobby side project but something more like Servo was, where you have paid experienced in domain developers.
- proto_lambda 5y ago"starting fresh with no baggage" also means starting fresh with no drivers. Having drivers for a wide range of hardware is a major factor in operating system adoption.
- psychoslave 5y agoDidn't FreeBSD incorporated an interface that allow to use Linux drivers? Not that I think it would make the point of having a bright new kernel easily compete with such a huge and firmly grounded project as Linux though. All the more, there already are multiple projects using Rust to build OSes out there, if I'm not mistaken.
- simion314 5y agoI was not suggesting this kernel to be used on laptops, it would be a server kernel, if it would actually be faster and safer then Google and Amazon will use it on their servers and they will make sure there are drivers, Google could use it in some mobile devices too if they care for safety. AMD has an open source driver so if desired that could be ported to Rust to also make sure the GPU is safe.
- xxpor 5y agoThings work the opposite way. In order to get companies to adopt things you need to get people working their interested in it. Which means they need to be able to run it on their PCs. There's a reason why x86 ate the world. The exception to this is when you can develop something and have a good case to use it yourself, like Google and Fuchsia. But I doubt Fuchsia will gain wide organic adoption because of the same factors.
- simion314 5y ago>Things work the opposite way. In order to get companies to adopt things you need to get people working their interested in it. This would mean that the only OSes are first created by hobbyists, then fanboys use it then a company adopts it. But there are commercial OSes and commercial software that are created by a company to solve a problem and not by random dudes and companies then adopts it. IMO is sad that we the tech industry are stuck with old OSes and old architecture while you have this giants that use open source software to make billions and they could find researching and creating of a few new revolutionary OSes like it happened in the past. And I don't mean desktop OS that will defeat Windows.
- xxpor 5y agoName a single successful (non-niche, stuff like INTEGRITY doesn't count) OS kernel created post-Windows NT 3.1 that's commercial. Even Mac OS X still runs Mach as a kernel. The model is dead, because of the internet. OSes have MASSIVE network effects.
- astrange 5y agoThere's several proprietary RTOSes in most every computer. There's one in the baseband on your phone, though it might be an L4 fork.
- Bancakes 5y agoWe simply don't have better kernels. POSIX is the epitome of infrastructure. That's it. We did it. It's like asking for something more than Turing completeness - we have everything, just optimise the existing code. To that end, introducing Rust is a pessimization.
- elihu 5y agoThe basic POSIX interface works, but it's hardly optimal. It has a lot of weird built-in assumptions that we're just so used to working around that it's hard to imagine it being any other way. As an example: why can a process only have one current working directory? Wouldn't it be nice to be able to have a process maintain pointers to two or more locations in the filesystem at once? Wouldn't it make software more modular if a library could "chdir" into some directory without worrying about breaking the application that depends on it? The filesystem APIs could be extended with a "CWD" handle argument that can be passed around sort of like a file descriptor instead of having one implicit CWD for the whole process. The same could be done with UIDs. Why not have processes that can use multiple UIDs? Again, you could have UID parameters to API functions that require authorization. POSIX is pretty good by the standards of 80's computers, but in a lot of ways it's showing its age. We can do better. But it's kind of depressing that OS interface design is treated as a solved problem, and so those interfaces stagnate.
- Dylan16807 5y ago> The filesystem APIs could be extended with a "CWD" handle argument that can be passed around Why would you even want a working directory at that point?
- elihu 5y agoWhat's the alternative? To use absolute paths for everything? That seems kind of tedious, and may be slightly less performant if the kernel has to do more dentry lookups. I think the idea of a current working directory is a reasonable one, it's just that the limitation that a process can only have one CWD at a time is kind of arbitrary when you think about it. I could even see having commands that take multiple CWDs. Like a move operation could take a source and a destination CWD as an alternative to specifying source and destination paths.
- scns 5y agoSorry for the snark in advance. Do you have an idea how many man years of work are in Linux? The estimated cost of developing it was 1.4 billion dollars in 2008. https://www.linuxfoundation.org/press-release/linux-foundation-publishes-study-estimating-the-value-of-linux/ https://www.linuxfoundation.org/press-release/linux-foundati...
- simion314 5y agoSure , but that all those years of work are not of creating new stuff, there is a lot of work on just modifying existing code and not breaking stuff. You do not need to get all Linux features at start, I would focus on the server stuff, support the popular server hardware and popular server work so filesystems and networking. I would hope some competent developers would write a new kernel from scratch then getting 10% of some Linux rustiffied. When you edit shit you need to make sure not break shit, so you are limited, you move slow and you have to implement backwards compatibility. Amazon,Google,Facebook could work on this if they care for security but probably using VMs is cheaper for them.
- dunefox 5y agoThat sounds pretty cheap actually.
- phendrenad2 5y agoOf course the Linux Foundation would say that the cost of developing Linux is a cool billion. They make money from Linux training after all. They want you to know: You're getting your money's worth.
- pferde 5y agoNot that I do not have respect for Linux, but that doesn't sound like much in an age when we're reading about modern aristocracy buying up useless microblogging platforms for forty-plus billions. :)
- scns 5y agoElon Musk is not in the OS business.
- ilovecaching 5y agoI don't think you understand the scope of what you're talking about. Linux is tens of millions of lines of code, most of which is drivers that have to be written by vendors. Vendors aren't going to write drivers for your hobby kernel. No one is using your hobby kernel. Bootstrapping a new kernel without billions of dollars to invest in development time is almost impossible, and anyone who is investing billions of dollars is likely going to have dubious proprietary reasons for doing so. A successful kernel is Rust is probably the worst thing that could happen to the open source community.
- qPM9l3XJrF 5y agoCould a new kernel implement a compatibility layer of some kind for Linux drivers? Or just expose the same API?
- rcxdude 5y agoNot very easily: Linux quite deliberately does not have any stable internal driver interface, so any such compatibility layer would have a very fast moving target to keep up with.
- simion314 5y ago>I don't think you understand the scope of what you're talking about. Linux is tens of millions of lines of code, most of which is drivers that have to be written by vendors. But if you are Google and you believe that this Rust kernel is super safe and fast and has clean code, and parallelism,async and candy ... how many drivers do google Data centers use ? After you prove the kernel is real good by using it in data centers and devices that need security you can slowly expand, for most devices you could create soem compatibility layer. Who knows if there are soem competent developeres hired to work on it they might use some better architecture, like keep the drivers outside the kernel.