Openwall GNU/*/Linux - a small security-enhanced Linux distro for servers
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date: Mon, 20 Jul 2015 00:09:03 +0300
From: Aleksey Cherepanov <lyosha@...nwall.com>
To: john-dev@...ts.openwall.com
Subject: Re: faster way to transpose matrix of words for sse and bits for
 bitslice

On Sun, Jul 19, 2015 at 11:50:50PM +0300, Aleksey Cherepanov wrote:
> I wrote a generator to populate code to transpose 64x64 bit matrix.
> 
> Straight forward generator to produce code like in Hacker's Delight:

Sorry! Previous variant is an older version of code with the
rearrangements. The straight forward variant is below:

perl -e '$m = 0x00000000FFFFFFFF; for ($j = 32; $j > 0; $j >>= 1, $m ^= $m << $j) { for ($k = 0; $k < 64; $k = ($k + $j + 1) & ~$j) { printf "swap(bits[%d], bits[%d], %d, 0x%016xULL);\n", $k, $k + $j, $j, $m; } }'

Notice that it does not produce swap1(), it has to be inserted
manually then.

Thanks!

-- 
Regards,
Aleksey Cherepanov

Powered by blists - more mailing lists

Your e-mail address:

Powered by Openwall GNU/*/Linux - Powered by OpenVZ