3 ms·
3 thoughts: 1. Using SIMD can be a big win, so yes. 2. SIMD (vectorization) is not the only optimization your compiler can do, the compiler has a model of the
by mhh__ 5y ago
3 thoughts:
1. Using SIMD can be a big win, so yes.
2. SIMD (vectorization) is not the only optimization your compiler can do, the compiler has a model of the processor so it can pick the right instructions and lay them out properly with as many tricks as they can describe generically.
3. Compilers have PGO. Use it (if you can). Compilers without PGO are a bit like an engine management unit with no sensors - all the gear, no idea. The compiler has to assume a hazy middle-of-the-road estimate of what branches will be exercised, whereas with PGO enabled your compiler can make the cold code smaller, and be more aggressive with hot code etc. etc.
- bee_rider 5y ago> all the gear, no idea I like this because it only makes sense in some accents. For example it wouldn't work in Boston where the r would only be pronounced on one of the words (idea).