Re:Unpythonic Python
by acqq on Thursday April 10, 2014 @03:51AM
(#7564728)
And my Visual C 6 compiles the above C to this x86 asm with a single conditional jump, just for the loop:
The magic is in the neg sbb combination: The neg changes reg to two's complement but also sets or clears the CF if the argument was != 0 then sbb reg,reg effectively moves CF to the reg avoiding conditional jump for != 0.
[ Parent
| on HN ]
There are no comments on this comment yet.