3 ms·
>> low-level C implementation compiled with -O3, the max optimization setting. IME, -O2 always comes out faster than -O3. In this case, though, the difference
by mtdewcmu 11y ago
>> low-level C implementation compiled with -O3, the max optimization setting.
IME, -O2 always comes out faster than -O3. In this case, though, the difference is fairly insignificant.
- KMag 11y agoNote that -Os and -Oz often give you faster code than -O2. Also -O3 doesn't turn on all optimizations. (Most notably, -O3 won't omit the frame pointer for leaf calls. Yes, omitting the frame pointer can make debugging harder.)