My favourite quick-prototyping tool for deciding whether or not a code rewrite has the intended effect on what the compiler produces:
Frob's loop code: https://godbolt.org/g/HEFMYz
Frob's manually unrolled code: https://godbolt.org/g/MZrQRH
JonnyCode's obfuscated XOR trickery: https://godbolt.org/g/3UAbN5
I'll admit that what JonnyCode's written is what you want, if you want a constant-time algorithm (which is something you want in some algorithms, to prevent a certain class of cryptographic attack)... but as you can see, the transformation from "do what I mean" code to the less-readable "do what I say" code does not have a noticeable effect on total instruction count or (admittedly eyeballed) clock cycles. In the worst case scenarios, there's just as many register/ALU round trips, and there's just as many fetches made.
But as Khatharr says, as will every other developer worth his salt: you don't know where the actual time is being spent in your algorithms until you profile it. Even when you guess correctly, it is only a guess. Analysis of evidence is more valuable than analysis of theory.