Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Tue, 10 Dec 2013 00:01:22 +0100
From: Lukas Odzioba <lukas.odzioba@...il.com>
To: john-dev@...ts.openwall.com
Subject: Re: md5crypt-opencl

2013/11/26 Lukas Odzioba <lukas.odzioba@...il.com>:
> After removing PUTCHAR(0x80) from md5_digest():
> Tahiti@...er: 2660K c/s
> TITAN: 2621K c/s
> GTX 570: 1198K c/s
> Tahiti@...l: 2359K c/s
>
>
> I'll try to get rid of 8-bit r/w now.

Just a small status update. I implemented that, there is no big
difference when passlength%8==0 and saltlength%8==0 (best case
scenario), but there is a significant difference when rw's are not
aligned.

All results for Tahiti@...er:
Previous code:
saltlen=8,passlen=8
2660K c/s

saltlen =8 passlen =9
2097K c/s

saltlen=9, various password lengths (1-12)
708497 c/s

Current:
saltlen=8, passlen=8
2741K c/s

saltlen =8, passlen =9
2542K c/s

saltlen=8, various password lengths (1-12)
1600K c/s

I still have conditions in code, but I wasn't able to make it faster
without them anyway (maybe someone else can).

inline void buf_update4(uint * buf, uint a,uint b,uint c,uint d,  uint offset)
{
switch(offset%4){
  case 0:
    buf[offset/4]=a;
    buf[(offset/4)+1]=b;
    buf[(offset/4)+2]=c;
    buf[(offset/4)+3]=d;
break;
  case 1:
    buf[offset/4]=(buf[offset/4]&0x000000ff)|(a<<8);
    buf[(offset/4)+1]=(a>>24)|(b<<8);
    buf[(offset/4)+2]=(b>>24)|(c<<8);
    buf[(offset/4)+3]=(c>>24)|(d<<8);
    buf[(offset/4)+4]=(buf[(offset/4)+4]&0xffffff00)|(d>>24);
break;
  case 2:
    buf[offset/4]=(buf[offset/4]&0x0000ffff)|(a<<16);
    buf[(offset/4)+1]=(a>>16)|(b<<16);
    buf[(offset/4)+2]=(b>>16)|(c<<16);
    buf[(offset/4)+3]=(c>>16)|(d<<16);
    buf[(offset/4)+4]=(buf[(offset/4)+4]&0xffff0000)|(d>>16);
break;
  case 3:
    buf[offset/4]=(buf[offset/4]&0x00ffffff)|(a<<24);
    buf[(offset/4)+1]=(a>>8)|(b<<24);
    buf[(offset/4)+2]=(b>>8)|(c<<24);
    buf[(offset/4)+3]=(c>>8)|(d<<24);
    buf[(offset/4)+4]=(buf[(offset/4)+4]&0xff000000)|(d>>8);
break;
}
}

This week I am planning to play a bit with local memory.
Lukas

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.