4 ms·
It's not even ranked first. Rust comes a good second to third behind C & C++ on most if not all tests listed on https://sites.google.com/view/energy-efficiency-
by vntok 9y ago
It's not even ranked first. Rust comes a good second to third behind C & C++ on most if not all tests listed on https://sites.google.com/view/energy-efficiency-languages/results https://sites.google.com/view/energy-efficiency-languages/re...
- RodericDay 9y ago"one of the most energy efficient" + "safe"
- icebraining 9y agoIn the normalized global results, at the bottom, Rust is above C++, and closer to C than C++ is to it.
- tmzt 9y agoThis is more a reflection of where the compiler is at, not the language. As a compiled, strongly-typed language without a GC, there is no theoretical reason why Rust could not be faster than C++. As the use of MIR and HIR (two intermediate languages used within the compiler) increases more optimizations taking advantage of the memory model could be added. In the current state, much of that work is left to LLVM which is designed more around the C/C++ memory model and only some of the ownership and aliasing information can be represented in that form. I am not arguing that Rust is faster now, only that it can be without fundamentally changing the language.
- bluejekyll 9y agoI just clicked that link. Rust is in fact first on a few of those categories. I’m not sure what your point is though, as the comment says that it is “one of” the most energy efficient languages, not the most energy efficient. It appears to gernerally be in the top three. A couple of points here. Rust is generally as fast as C and C++, but on top of that it is memory and data race safe. Said another way, there is a safe language alternative which doesn’t have the pitfalls of C/C++, and that’s a great thing!