Memory safety is a nice thing if you have full control over all the code you use. But as long as there is a unsafe keeword neccersary it is futile. Any change in any unsave code may break all the nice borrow checking in only one call. I even think telling the user they are memory save but call unsafe code in the os layer is a extreme bad idea. Real memory safety needs a all or noting approach. I use rust binarys that fail with panics because something out if rusts scope goes wrong, mostly memory related
A few observations:
- I always get the sense we all live in our own little bubbles.
- It's clearly not economically viable to manually transition all codebases to rust or any other mem-safe lang.
- How cute that the paper points out that any mem-safe language is fine, though rust is always the prime example. Almost as if this is a rust marketing piece, but the author wants to move away from the controversy.
- Is mem-safety even that important when hardware has mitigations like MTE (or capabilities in the future)?
- Is mem-safety even important when we're going through the tectonic shift of AI developing code and AI reviewing it! Where limitations of human perception/attention are no longer that relevant?
> C and C++ won’t die, but they will likely decline and become legacy languages like Cobol or Ada.
Yes, any day now, the languages powering Linux, every major RDBMS, every distributed storage engine, every hypervisor, every browser engine, every AAA game engine, LLVM/GCC toolchains, and the embedded world are going to turn into COBOL - because Google wrote some Android Binder code in Rust, and a government working group published a PDF. For sure.
But if anything the "In Budget, On Schedule" section makes a surprisingly lucid case for why you shouldn’t rewrite working systems.
It seems like you've got a steady state fallacy. It is true that things are as they are, and yet it's also true that they weren't always that way and can be expected to be different in the future.
"Nothing will change" is probably the stupidest possible guess in any dynamic system.
Take a system where we have play-by-play data over a long period, Firefox. Ten years ago C++ makes up about 60% and C another 25% of the codebase and there was a trifling amount of Rust as it was newly introduced. They didn't stop writing C or C++ but they did write a lot of Rust, and so now only about 45% is C++ and C about 15%.
Legacy languages don't "turn into COBOL", they remain exactly as they are, like COBOL did, and the world changes anyway.
It's more like "Nothing will change significantly in the foreseeable future", which might be true - A lot of C or C++ codebases will never migrate to other languages, just like a lot of the surviving COBOL codebases haven't been successfully migrated to anything else for 50+ years.
There is a lesson in here: there are codebases that resist rewrites (I've seen many Java and C# projects try to replace COBOL applications and failing spectacularly). I imagine some parts of Linux will remain C for the foreseeable future, but the Rust corpus in it will only increase. Same for Firefox - some parts are just hard to express in different semantics (and, if you write Rust with C semantics, you are just writing C with a different syntax).
His point is that the old code bases do not get displaced because the language they were built on is obsolete.
The only thing that can obsolete those code bases isn't yet another AI boosted language, the thing that makes the old code bases obsolete is a newer code base that is either simply better on a technical basis or is easier to use. At least one of those paths must lead to mass appeal to take advantage of network effects in favor of the new code base.
Unfortunately the "change" goes into the wrong overall direction for Firefox. If the market share keeps shrinking (in those same 10 years from around 8% to around 2% today) it might be completely dead before the transition to Rust is finished (and it doesn't look like Rust made them any faster, for instance the WebGPU implementation in Firefox is still not nearly in the same shape as Chrome's or Safari's).
(and FWIW, currently I wonder how "LLM hardened" C code will compare to Rust, from what I've seen so far LLMs do a pretty good job at finding latent bugs and edge cases in C code, e.g. specific language properties might not play such a big role in the future as they did in the past)
>(and FWIW, currently I wonder how "LLM hardened" C code will compare to Rust, from what I've seen so far LLMs do a pretty good job at finding latent bugs and edge cases in C code, e.g. specific language properties might not play such a big role in the future as they did in the past)
Isn't this the ultimate self own? Saying that your language is so bad that only AI can help you fix your own code from containing severe security problems. The smart enough C developer isn't even human anymore.
Writing C code by hand and have it reviewed by LLMs remains an enjoyable middleground. In that scenario, the LLM is just another static analyzer tool.
Typical Rust OTH is neither a joy to read nor to write for humans, so the LLM remains the only option to create and maintain Rust codebases ;P
Also memory safety isn't the only thing that matters, iteration speed and code simplicity might too, and large C code bases build infinitely faster and are also easier to read and understand than typical Rust or C++ codebases)
Memory safety is a nice thing if you have full control over all the code you use. But as long as there is a unsafe keeword neccersary it is futile. Any change in any unsave code may break all the nice borrow checking in only one call. I even think telling the user they are memory save but call unsafe code in the os layer is a extreme bad idea. Real memory safety needs a all or noting approach. I use rust binarys that fail with panics because something out if rusts scope goes wrong, mostly memory related
No mention of Fil-C?
A few observations: - I always get the sense we all live in our own little bubbles.
- It's clearly not economically viable to manually transition all codebases to rust or any other mem-safe lang. - How cute that the paper points out that any mem-safe language is fine, though rust is always the prime example. Almost as if this is a rust marketing piece, but the author wants to move away from the controversy. - Is mem-safety even that important when hardware has mitigations like MTE (or capabilities in the future)? - Is mem-safety even important when we're going through the tectonic shift of AI developing code and AI reviewing it! Where limitations of human perception/attention are no longer that relevant?
> C and C++ won’t die, but they will likely decline and become legacy languages like Cobol or Ada.
Yes, any day now, the languages powering Linux, every major RDBMS, every distributed storage engine, every hypervisor, every browser engine, every AAA game engine, LLVM/GCC toolchains, and the embedded world are going to turn into COBOL - because Google wrote some Android Binder code in Rust, and a government working group published a PDF. For sure.
But if anything the "In Budget, On Schedule" section makes a surprisingly lucid case for why you shouldn’t rewrite working systems.
It seems like you've got a steady state fallacy. It is true that things are as they are, and yet it's also true that they weren't always that way and can be expected to be different in the future.
"Nothing will change" is probably the stupidest possible guess in any dynamic system.
Take a system where we have play-by-play data over a long period, Firefox. Ten years ago C++ makes up about 60% and C another 25% of the codebase and there was a trifling amount of Rust as it was newly introduced. They didn't stop writing C or C++ but they did write a lot of Rust, and so now only about 45% is C++ and C about 15%.
Legacy languages don't "turn into COBOL", they remain exactly as they are, like COBOL did, and the world changes anyway.
> "Nothing will change"
It's more like "Nothing will change significantly in the foreseeable future", which might be true - A lot of C or C++ codebases will never migrate to other languages, just like a lot of the surviving COBOL codebases haven't been successfully migrated to anything else for 50+ years.
There is a lesson in here: there are codebases that resist rewrites (I've seen many Java and C# projects try to replace COBOL applications and failing spectacularly). I imagine some parts of Linux will remain C for the foreseeable future, but the Rust corpus in it will only increase. Same for Firefox - some parts are just hard to express in different semantics (and, if you write Rust with C semantics, you are just writing C with a different syntax).
His point is that the old code bases do not get displaced because the language they were built on is obsolete.
The only thing that can obsolete those code bases isn't yet another AI boosted language, the thing that makes the old code bases obsolete is a newer code base that is either simply better on a technical basis or is easier to use. At least one of those paths must lead to mass appeal to take advantage of network effects in favor of the new code base.
Unfortunately the "change" goes into the wrong overall direction for Firefox. If the market share keeps shrinking (in those same 10 years from around 8% to around 2% today) it might be completely dead before the transition to Rust is finished (and it doesn't look like Rust made them any faster, for instance the WebGPU implementation in Firefox is still not nearly in the same shape as Chrome's or Safari's).
(and FWIW, currently I wonder how "LLM hardened" C code will compare to Rust, from what I've seen so far LLMs do a pretty good job at finding latent bugs and edge cases in C code, e.g. specific language properties might not play such a big role in the future as they did in the past)
Let's hope AI can help them catch up. Also, other parties might be interested in having more than one viable browser core engine.
>(and FWIW, currently I wonder how "LLM hardened" C code will compare to Rust, from what I've seen so far LLMs do a pretty good job at finding latent bugs and edge cases in C code, e.g. specific language properties might not play such a big role in the future as they did in the past)
Isn't this the ultimate self own? Saying that your language is so bad that only AI can help you fix your own code from containing severe security problems. The smart enough C developer isn't even human anymore.
Writing C code by hand and have it reviewed by LLMs remains an enjoyable middleground. In that scenario, the LLM is just another static analyzer tool.
Typical Rust OTH is neither a joy to read nor to write for humans, so the LLM remains the only option to create and maintain Rust codebases ;P
Also memory safety isn't the only thing that matters, iteration speed and code simplicity might too, and large C code bases build infinitely faster and are also easier to read and understand than typical Rust or C++ codebases)