In any case with large values of k the branch prediction will be
right almost all of the time, explaining why this form is faster
than modulo as modulo is fairly slow while this is a correctly
predicted branch doing an addition if it doesn't make it
branchless. The branchless version gives the same time result as
branched, is there a way to force that line not to optimized to
compare the predicted version?
- popFront causing more memory to be used ixid
- Re: popFront causing more memory to be used Era Scarecrow
- Re: popFront causing more memory to be used ixid
- Re: popFront causing more memory to be used bearophile
- Re: popFront causing more memory to be u... ixid
- Re: popFront causing more memory to... bearophile
- Re: popFront causing more memor... ixid
- Re: popFront causing more m... bearophile
- Re: popFront causing more m... bearophile
- Re: popFront causing more m... ixid
- Re: popFront causing more m... ixid
- Re: popFront causing more m... bearophile
- Re: popFront causing more m... ixid
- Re: popFront causing more m... bearophile
- Re: popFront causing more m... ixid
- Re: popFront causing more memory to be u... Jonathan M Davis