4 ms·
I support the push towards memory safe languages but emphasizing Rust in the way this paper does seems misguided. It creates a false dichotomy between c style l
by diffxx 2y ago
I support the push towards memory safe languages but emphasizing Rust in the way this paper does seems misguided. It creates a false dichotomy between c style languages without safety guarantees and Rust as though there are no other alternatives. There are other approaches and models that can also achieve bare metal performance for many problems without taking in all of the complexity of Rust. Moreover, we will never settle on one language to rule them all (and if we do I am 100% sure it will not be Rust), so we should be emphasizing approaches to mitigating vulnerabilities rather than prescribing a particular tool.
- mmoskal 2y agoWhich alternatives exactly? Mainstream languages like Go and Swift use a GC and don't allow the same level of control over memory layout. There are probably some reasons Rust is only non-C language to get into Linux kernel.
- _orz_ 2y agoThat’s just not true, Swift doesn’t use GC but reference counting.
- super_flanker 2y agoReference Counting is a type of GC.
- bdjsiqoocwk 2y agoStop using words you don't understand, it's dishonest.
- _orz_ 2y agoSorry? So obviously with GC one means managed GC. Otherwise the comment above doesn’t make any sense at all since then Rust itself would use GC because it also supports reference counting. Strictly speaking you could obviously say reference counting is a form of GC. So to avoid GC you then surely recommend people to use C since that, in contrast to Rust, Swift, C++ and many others, really doesn’t use any GC, neither managed nor reference counting based.
- sshine 2y agoReference counting is a form of GC. Saying Swift, or Perl, are not GC’ed would be misleading. In Rust, reference counting is opt-in for individual objects. It is a necessity for any powerful, low-level language to be able to implement any high-level feature. You can, after all, also implement reference counting in C. To avoid GC, you need a language where it’s opt-in. For example C++ or Zig, but not OCaml.
- bdjsiqoocwk 2y agoC++ also got into the Linux kernel at some point in the past, it just failed to stay there. Let's see how it fares for Rust.
- nequo 2y agoDo you have any sources on when this happened and in which part of the kernel? My search has turned up nothing. I assume LWN or some other Linux adjacent news outlet should have written something about it.