4 ms·
In fact, Rust's version compiles down to pretty much the optimal looping form. It will even vectorize your iterations using SIMD.
by stouset 6y ago
In fact, Rust's version compiles down to pretty much the optimal looping form. It will even vectorize your iterations using SIMD.
- throwaway894345 6y agoRust is seriously cool in this regard, but Go aspires to be different, namely more C-like and less C++-like. This means a dumber, faster compiler that is easier to intuit about, for better or worse. Rust is such an amazing piece of engineering (moreso an amazing process and culture for producing an amazing language), but I think Go’s approach is right for a whole lot of software—lots of things don’t need to be insanely performant (lots of things are chugging along in Python, which runs 2-3 orders of magnitude slower than Go) but we do need to be able to iterate on them quickly in a development context involving dozens or hundreds of other people.