3 ms·
The article talks about three different levels of optimization. - Detect and trap overflows. - Assume that two's complement math is a thing, and overflow can
by Filligree 11y ago
The article talks about three different levels of optimization.
- Detect and trap overflows.
- Assume that two's complement math is a thing, and overflow can lead to additions producing negative values.
- Assume that overflow never happens, and optimize on this basis.
Rust does #1 in debug mode, #2 in release mode except when explicitly told not to. C compilers do #3. #3 is what leads to developers screaming at their compilers.