4 ms·
Absolutely, but that's one of the nice things about Rust, it benchmarks almost exactly the same as C. The benefits rust offers are almost entirely in their lexe
by chris37879 5y ago
Absolutely, but that's one of the nice things about Rust, it benchmarks almost exactly the same as C. The benefits rust offers are almost entirely in their lexer / analyzer, that's the whole point. Dart does a similar thing with its sound null safety, being able to guarantee what can and can't be null / invalid pointer removes the need for the language to test those cases, your CPU doesn't give a shit if you read uninitialized memory and get into a bad state, but your language does, so being able to divert all that checking to compile time is a nice boost in runtime perf.