|
|
|
@ -798,7 +798,7 @@ void scrypt_core(uint4 X[8], __global uint4*restrict lookup)
@@ -798,7 +798,7 @@ void scrypt_core(uint4 X[8], __global uint4*restrict lookup)
|
|
|
|
|
#pragma unroll |
|
|
|
|
for(uint z=0; z<zSIZE; ++z) |
|
|
|
|
lookup[CO] = X[z]; |
|
|
|
|
for(uint i=0; i<LOOKUP_GAP; ++i) |
|
|
|
|
for(uint i=0; i<LOOKUP_GAP; ++i) |
|
|
|
|
salsa(X); |
|
|
|
|
} |
|
|
|
|
#if (LOOKUP_GAP != 1) && (LOOKUP_GAP != 2) && (LOOKUP_GAP != 4) && (LOOKUP_GAP != 8) |
|
|
|
@ -811,7 +811,7 @@ void scrypt_core(uint4 X[8], __global uint4*restrict lookup)
@@ -811,7 +811,7 @@ void scrypt_core(uint4 X[8], __global uint4*restrict lookup)
|
|
|
|
|
salsa(X); |
|
|
|
|
} |
|
|
|
|
#endif |
|
|
|
|
for (uint i=0; i<N[NFACTOR]; ++i) |
|
|
|
|
for (uint i=0; i<N[NFACTOR]; ++i) |
|
|
|
|
{ |
|
|
|
|
uint4 V[8]; |
|
|
|
|
uint j = X[7].x & (N[NFACTOR]-1); |
|
|
|
@ -826,7 +826,7 @@ void scrypt_core(uint4 X[8], __global uint4*restrict lookup)
@@ -826,7 +826,7 @@ void scrypt_core(uint4 X[8], __global uint4*restrict lookup)
|
|
|
|
|
salsa(V); |
|
|
|
|
#else |
|
|
|
|
uint val = j%LOOKUP_GAP; |
|
|
|
|
for (uint z=0; z<val; ++z) |
|
|
|
|
for (uint z=0; z<val; ++z) |
|
|
|
|
salsa(V); |
|
|
|
|
#endif |
|
|
|
|
|
|
|
|
@ -861,7 +861,7 @@ const uint4 midstate0, const uint4 midstate16, const uint target)
@@ -861,7 +861,7 @@ const uint4 midstate0, const uint4 midstate16, const uint target)
|
|
|
|
|
SHA256(&tstate0, &tstate1, input[0],input[1],input[2],input[3]); |
|
|
|
|
|
|
|
|
|
#pragma unroll |
|
|
|
|
for (uint i=0; i<4; i++) |
|
|
|
|
for (uint i=0; i<4; i++) |
|
|
|
|
{ |
|
|
|
|
pad0 = tstate0; |
|
|
|
|
pad1 = tstate1; |
|
|
|
|