Before v5.20 the copy on write feature of string was not activated by default. This means that you may win a little time by avoiding to copy the strings in multiple scalars: print $output pack("v*", unpack("n*", scalar <$fh>));
In reply to Re: Fastest byteswap (little endian to big endian (eg. 34127856 -> 12345678)
by Eily
in thread Fastest byteswap (little endian to big endian (eg. 34127856 -> 12345678)
by james28909
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |