3 ms·
I've grown so paranoid of optimizing compilers this wouldn't even cross my mind. But it is correct, right?
by hoseja 7y ago
I've grown so paranoid of optimizing compilers this wouldn't even cross my mind. But it is correct, right?
- AlbertoGP 7y agoNot OP, but the “volatile” qualifier should prevent the compiler from optimizing it out.
- Gibbon1 7y agoYeah should. Multicore super scalar processors make me nervous about my assumptions. I wouldn't put it past one of them to realize that the result is unused and nop it. It's always good to check.