Although it's a technique more appropriate in a C program.
In Perl, log($_)/log(2) benchmarks faster.
(assuming it rounds properly at the boundaries)
Update: My earlier timethese qq{} may have been misleading.
With timethese sub{} the | >> method comes out faster