Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re^4: Efficient bit-twiddling in Perl.

by BrowserUk (Patriarch)
on Mar 01, 2013 at 12:40 UTC ( [id://1021241]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    #! perl -slw
    use strict;
    ...
        stuff( unpack 'vccc', join'',map{ pack'b*', $_ } unpack 'a14a6a6a6
    +', unpack 'B32', pack 'N', $_ );
    }
    printf "(un)pack  took: %.12f seconds\n", ( time() - $start ) / $ITERS
    +;
    
  2. or download this
    C:\test>1021064
    Shift&and took: 0.000000606833 seconds
      Lookup  took: 0.000000485629 seconds
      Lookup2 took: 0.000000669586 seconds
    (un)pack  took: 0.000007564075 seconds
    

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1021241]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others imbibing at the Monastery: (9)
As of 2024-04-23 21:59 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found