Those are almost, but not quite, the same due to their behavior in the case of 'continue;'.
I remember reading (long ago!) about how some compilers were found to executefaster thanCode:for(;;) { /* ... */ }
or variants thereof because the compiler would actually perform an evaluation of testing 1 for truth.Code:while (1) { /* ... */ }
Basically... you just can't assume much anything about how optimization works. Just have faith that it does.