Re:Ask HN: When Will Rust-for-Linux Be Completed?
by worldsavior on Saturday December 10, 2022 @03:10PM
(#33936318)
Isn't memory safety needed in all cases?
[ Parent
| on HN ]
Re:Ask HN: When Will Rust-for-Linux Be Completed?
by smoldesu on Saturday December 10, 2022 @03:17PM
(#33936405)
Not really. There are a lot of things we can do fairly reliably without guaranteed memory safety, and the danger-zones that do exist are pretty clearly mapped and well-known to kernel devs. There are also a lot of things that do need memory safety, but the architecture is usually designed to minimize UB and keep things simple as possible. If you manage to segfault a modern Linux kernel, you're probably using extremely unsupported hardware.
Rewriting Linux in Rust is veritably impossible anyways. It would require re-reviewing over 3 decades of kernel contributions and locking down high-quality 1:1 replications of the previous code. It's just not going to happen, at least not while the standards for merging to the kernel is so high.