Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Sun, 06 May 2012 13:26:01 +0200
From: magnum <>
Subject: Re: OpenCL SWAP64 on 7970

On 05/06/2012 03:55 AM, myrice wrote:
> Claudio, all
> It seems that 7970 has some strange behaviors when we perform bitwise
> operation with ulong type. SWAP64 didn't work correctly.
> xsha512-opencl and cryptsha512-opencl are all influenced. Here is what
> I get from my debugging.
> With a 64bit variable n, if we do (n) << 56, no problem. However, if
> we do (n) & 0xff00 << 24 or << 32 or << 40, the result will be 0. It
> seems that the & operation converts the result to a 32bit variable. So
> the << 24 or above will make the result to be 0.

Have you tried using 0xff00UL instead? I had to use 0xffU for some of my
32-bit macros, otherwise it would become signed.


Powered by blists - more mailing lists

Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.