Prepare for a more dynamic #pragma unroll use
[hashcat.git] / OpenCL / m10500.cl
index cf763af..a24469f 100644 (file)
@@ -56,7 +56,9 @@ void rc4_init_16 (__local RC4_KEY *rc4_key, const u32 data[4])
 
   __local u32 *ptr = (__local u32 *) rc4_key->S;
 
+  #ifdef _unroll
   #pragma unroll
+  #endif
   for (u32 i = 0; i < 64; i++)
   {
     *ptr++ = v; v += a;
@@ -64,7 +66,9 @@ void rc4_init_16 (__local RC4_KEY *rc4_key, const u32 data[4])
 
   u32 j = 0;
 
+  #ifdef _unroll
   #pragma unroll
+  #endif
   for (u32 i = 0; i < 16; i++)
   {
     u32 idx = i * 16;
@@ -103,7 +107,9 @@ void rc4_init_16 (__local RC4_KEY *rc4_key, const u32 data[4])
 
 u8 rc4_next_16 (__local RC4_KEY *rc4_key, u8 i, u8 j, const u32 in[4], u32 out[4])
 {
+  #ifdef _unroll
   #pragma unroll
+  #endif
   for (u32 k = 0; k < 4; k++)
   {
     u32 xor4 = 0;