2 * Author......: Jens Steube <jens.steube@gmail.com>
10 #include "inc_vendor.cl"
11 #include "inc_hash_constants.h"
12 #include "inc_hash_functions.cl"
13 #include "inc_types.cl"
14 #include "inc_common.cl"
15 #include "inc_simd.cl"
18 #define MD5_STEP_REV(f,a,b,c,d,x,t,s) \
21 a = rotr32_S (a, s); \
27 #define MD5_STEP_REV1(f,a,b,c,d,x,t,s) \
30 a = rotr32_S (a, s); \
35 void m00000m (u32 w[16], const u32 pw_len, __global pw_t *pws, __global kernel_rule_t *rules_buf, __global comb_t *combs_buf, __constant u32x * words_buf_r, __global void *tmps, __global void *hooks, __global u32 *bitmaps_buf_s1_a, __global u32 *bitmaps_buf_s1_b, __global u32 *bitmaps_buf_s1_c, __global u32 *bitmaps_buf_s1_d, __global u32 *bitmaps_buf_s2_a, __global u32 *bitmaps_buf_s2_b, __global u32 *bitmaps_buf_s2_c, __global u32 *bitmaps_buf_s2_d, __global plain_t *plains_buf, __global digest_t *digests_buf, __global u32 *hashes_shown, __global salt_t *salt_bufs, __global void *esalt_bufs, __global u32 *d_return_buf, __global u32 *d_scryptV0_buf, __global u32 *d_scryptV1_buf, __global u32 *d_scryptV2_buf, __global u32 *d_scryptV3_buf, const u32 bitmap_mask, const u32 bitmap_shift1, const u32 bitmap_shift2, const u32 salt_pos, const u32 loop_pos, const u32 loop_cnt, const u32 il_cnt, const u32 digests_cnt, const u32 digests_offset)
41 const u32 gid = get_global_id (0);
42 const u32 lid = get_local_id (0);
55 for (u32 il_pos = 0; il_pos < il_cnt; il_pos += VECT_SIZE)
57 const u32x w0r = words_buf_r[il_pos / VECT_SIZE];
59 //const u32x w0 = w0l | w0r;
78 const u32 out_len = mangle(w0, w1, pw_len);
79 append_0x80_2x4_VV (w0, w1, out_len);
88 MD5_STEP (MD5_Fo, a, b, c, d, w0[0], MD5C00, MD5S00);
89 MD5_STEP (MD5_Fo, d, a, b, c, w0[1], MD5C01, MD5S01);
90 MD5_STEP (MD5_Fo, c, d, a, b, w0[2], MD5C02, MD5S02);
91 MD5_STEP (MD5_Fo, b, c, d, a, w0[3], MD5C03, MD5S03);
92 MD5_STEP (MD5_Fo, a, b, c, d, w1[0], MD5C04, MD5S00);
93 MD5_STEP (MD5_Fo, d, a, b, c, w1[1], MD5C05, MD5S01);
94 MD5_STEP (MD5_Fo, c, d, a, b, w1[2], MD5C06, MD5S02);
95 MD5_STEP (MD5_Fo, b, c, d, a, w1[3], MD5C07, MD5S03);
96 MD5_STEP (MD5_Fo, a, b, c, d, w2[0], MD5C08, MD5S00);
97 MD5_STEP (MD5_Fo, d, a, b, c, w2[1], MD5C09, MD5S01);
98 MD5_STEP (MD5_Fo, c, d, a, b, w2[2], MD5C0a, MD5S02);
99 MD5_STEP (MD5_Fo, b, c, d, a, w2[3], MD5C0b, MD5S03);
100 MD5_STEP (MD5_Fo, a, b, c, d, w3[0], MD5C0c, MD5S00);
101 MD5_STEP (MD5_Fo, d, a, b, c, w3[1], MD5C0d, MD5S01);
102 MD5_STEP (MD5_Fo, c, d, a, b, w3[2], MD5C0e, MD5S02);
103 MD5_STEP (MD5_Fo, b, c, d, a, w3[3], MD5C0f, MD5S03);
105 MD5_STEP (MD5_Go, a, b, c, d, w0[1], MD5C10, MD5S10);
106 MD5_STEP (MD5_Go, d, a, b, c, w1[2], MD5C11, MD5S11);
107 MD5_STEP (MD5_Go, c, d, a, b, w2[3], MD5C12, MD5S12);
108 MD5_STEP (MD5_Go, b, c, d, a, w0[0], MD5C13, MD5S13);
109 MD5_STEP (MD5_Go, a, b, c, d, w1[1], MD5C14, MD5S10);
110 MD5_STEP (MD5_Go, d, a, b, c, w2[2], MD5C15, MD5S11);
111 MD5_STEP (MD5_Go, c, d, a, b, w3[3], MD5C16, MD5S12);
112 MD5_STEP (MD5_Go, b, c, d, a, w1[0], MD5C17, MD5S13);
113 MD5_STEP (MD5_Go, a, b, c, d, w2[1], MD5C18, MD5S10);
114 MD5_STEP (MD5_Go, d, a, b, c, w3[2], MD5C19, MD5S11);
115 MD5_STEP (MD5_Go, c, d, a, b, w0[3], MD5C1a, MD5S12);
116 MD5_STEP (MD5_Go, b, c, d, a, w2[0], MD5C1b, MD5S13);
117 MD5_STEP (MD5_Go, a, b, c, d, w3[1], MD5C1c, MD5S10);
118 MD5_STEP (MD5_Go, d, a, b, c, w0[2], MD5C1d, MD5S11);
119 MD5_STEP (MD5_Go, c, d, a, b, w1[3], MD5C1e, MD5S12);
120 MD5_STEP (MD5_Go, b, c, d, a, w3[0], MD5C1f, MD5S13);
122 MD5_STEP (MD5_H , a, b, c, d, w1[1], MD5C20, MD5S20);
123 MD5_STEP (MD5_H , d, a, b, c, w2[0], MD5C21, MD5S21);
124 MD5_STEP (MD5_H , c, d, a, b, w2[3], MD5C22, MD5S22);
125 MD5_STEP (MD5_H , b, c, d, a, w3[2], MD5C23, MD5S23);
126 MD5_STEP (MD5_H , a, b, c, d, w0[1], MD5C24, MD5S20);
127 MD5_STEP (MD5_H , d, a, b, c, w1[0], MD5C25, MD5S21);
128 MD5_STEP (MD5_H , c, d, a, b, w1[3], MD5C26, MD5S22);
129 MD5_STEP (MD5_H , b, c, d, a, w2[2], MD5C27, MD5S23);
130 MD5_STEP (MD5_H , a, b, c, d, w3[1], MD5C28, MD5S20);
131 MD5_STEP (MD5_H , d, a, b, c, w0[0], MD5C29, MD5S21);
132 MD5_STEP (MD5_H , c, d, a, b, w0[3], MD5C2a, MD5S22);
133 MD5_STEP (MD5_H , b, c, d, a, w1[2], MD5C2b, MD5S23);
134 MD5_STEP (MD5_H , a, b, c, d, w2[1], MD5C2c, MD5S20);
135 MD5_STEP (MD5_H , d, a, b, c, w3[0], MD5C2d, MD5S21);
136 MD5_STEP (MD5_H , c, d, a, b, w3[3], MD5C2e, MD5S22);
137 MD5_STEP (MD5_H , b, c, d, a, w0[2], MD5C2f, MD5S23);
139 MD5_STEP (MD5_I , a, b, c, d, w0[0], MD5C30, MD5S30);
140 MD5_STEP (MD5_I , d, a, b, c, w1[3], MD5C31, MD5S31);
141 MD5_STEP (MD5_I , c, d, a, b, w3[2], MD5C32, MD5S32);
142 MD5_STEP (MD5_I , b, c, d, a, w1[1], MD5C33, MD5S33);
143 MD5_STEP (MD5_I , a, b, c, d, w3[0], MD5C34, MD5S30);
144 MD5_STEP (MD5_I , d, a, b, c, w0[3], MD5C35, MD5S31);
145 MD5_STEP (MD5_I , c, d, a, b, w2[2], MD5C36, MD5S32);
146 MD5_STEP (MD5_I , b, c, d, a, w0[1], MD5C37, MD5S33);
147 MD5_STEP (MD5_I , a, b, c, d, w2[0], MD5C38, MD5S30);
148 MD5_STEP (MD5_I , d, a, b, c, w3[3], MD5C39, MD5S31);
149 MD5_STEP (MD5_I , c, d, a, b, w1[2], MD5C3a, MD5S32);
150 MD5_STEP (MD5_I , b, c, d, a, w3[1], MD5C3b, MD5S33);
151 MD5_STEP (MD5_I , a, b, c, d, w1[0], MD5C3c, MD5S30);
152 MD5_STEP (MD5_I , d, a, b, c, w2[3], MD5C3d, MD5S31);
153 MD5_STEP (MD5_I , c, d, a, b, w0[2], MD5C3e, MD5S32);
154 MD5_STEP (MD5_I , b, c, d, a, w2[1], MD5C3f, MD5S33);
156 COMPARE_M_SIMD (a, d, c, b);
165 void m00000m_orig (u32 w[16], const u32 pw_len, __global pw_t *pws, __global kernel_rule_t *rules_buf, __global comb_t *combs_buf, __constant u32x * words_buf_r, __global void *tmps, __global void *hooks, __global u32 *bitmaps_buf_s1_a, __global u32 *bitmaps_buf_s1_b, __global u32 *bitmaps_buf_s1_c, __global u32 *bitmaps_buf_s1_d, __global u32 *bitmaps_buf_s2_a, __global u32 *bitmaps_buf_s2_b, __global u32 *bitmaps_buf_s2_c, __global u32 *bitmaps_buf_s2_d, __global plain_t *plains_buf, __global digest_t *digests_buf, __global u32 *hashes_shown, __global salt_t *salt_bufs, __global void *esalt_bufs, __global u32 *d_return_buf, __global u32 *d_scryptV0_buf, __global u32 *d_scryptV1_buf, __global u32 *d_scryptV2_buf, __global u32 *d_scryptV3_buf, const u32 bitmap_mask, const u32 bitmap_shift1, const u32 bitmap_shift2, const u32 salt_pos, const u32 loop_pos, const u32 loop_cnt, const u32 il_cnt, const u32 digests_cnt, const u32 digests_offset)
171 const u32 gid = get_global_id (0);
172 const u32 lid = get_local_id (0);
178 const u32 F_w0c00 = 0 + MD5C00;
179 const u32 F_w1c01 = w[ 1] + MD5C01;
180 const u32 F_w2c02 = w[ 2] + MD5C02;
181 const u32 F_w3c03 = w[ 3] + MD5C03;
182 const u32 F_w4c04 = w[ 4] + MD5C04;
183 const u32 F_w5c05 = w[ 5] + MD5C05;
184 const u32 F_w6c06 = w[ 6] + MD5C06;
185 const u32 F_w7c07 = w[ 7] + MD5C07;
186 const u32 F_w8c08 = w[ 8] + MD5C08;
187 const u32 F_w9c09 = w[ 9] + MD5C09;
188 const u32 F_wac0a = w[10] + MD5C0a;
189 const u32 F_wbc0b = w[11] + MD5C0b;
190 const u32 F_wcc0c = w[12] + MD5C0c;
191 const u32 F_wdc0d = w[13] + MD5C0d;
192 const u32 F_wec0e = w[14] + MD5C0e;
193 const u32 F_wfc0f = w[15] + MD5C0f;
195 const u32 G_w1c10 = w[ 1] + MD5C10;
196 const u32 G_w6c11 = w[ 6] + MD5C11;
197 const u32 G_wbc12 = w[11] + MD5C12;
198 const u32 G_w0c13 = 0 + MD5C13;
199 const u32 G_w5c14 = w[ 5] + MD5C14;
200 const u32 G_wac15 = w[10] + MD5C15;
201 const u32 G_wfc16 = w[15] + MD5C16;
202 const u32 G_w4c17 = w[ 4] + MD5C17;
203 const u32 G_w9c18 = w[ 9] + MD5C18;
204 const u32 G_wec19 = w[14] + MD5C19;
205 const u32 G_w3c1a = w[ 3] + MD5C1a;
206 const u32 G_w8c1b = w[ 8] + MD5C1b;
207 const u32 G_wdc1c = w[13] + MD5C1c;
208 const u32 G_w2c1d = w[ 2] + MD5C1d;
209 const u32 G_w7c1e = w[ 7] + MD5C1e;
210 const u32 G_wcc1f = w[12] + MD5C1f;
212 const u32 H_w5c20 = w[ 5] + MD5C20;
213 const u32 H_w8c21 = w[ 8] + MD5C21;
214 const u32 H_wbc22 = w[11] + MD5C22;
215 const u32 H_wec23 = w[14] + MD5C23;
216 const u32 H_w1c24 = w[ 1] + MD5C24;
217 const u32 H_w4c25 = w[ 4] + MD5C25;
218 const u32 H_w7c26 = w[ 7] + MD5C26;
219 const u32 H_wac27 = w[10] + MD5C27;
220 const u32 H_wdc28 = w[13] + MD5C28;
221 const u32 H_w0c29 = 0 + MD5C29;
222 const u32 H_w3c2a = w[ 3] + MD5C2a;
223 const u32 H_w6c2b = w[ 6] + MD5C2b;
224 const u32 H_w9c2c = w[ 9] + MD5C2c;
225 const u32 H_wcc2d = w[12] + MD5C2d;
226 const u32 H_wfc2e = w[15] + MD5C2e;
227 const u32 H_w2c2f = w[ 2] + MD5C2f;
229 const u32 I_w0c30 = 0 + MD5C30;
230 const u32 I_w7c31 = w[ 7] + MD5C31;
231 const u32 I_wec32 = w[14] + MD5C32;
232 const u32 I_w5c33 = w[ 5] + MD5C33;
233 const u32 I_wcc34 = w[12] + MD5C34;
234 const u32 I_w3c35 = w[ 3] + MD5C35;
235 const u32 I_wac36 = w[10] + MD5C36;
236 const u32 I_w1c37 = w[ 1] + MD5C37;
237 const u32 I_w8c38 = w[ 8] + MD5C38;
238 const u32 I_wfc39 = w[15] + MD5C39;
239 const u32 I_w6c3a = w[ 6] + MD5C3a;
240 const u32 I_wdc3b = w[13] + MD5C3b;
241 const u32 I_w4c3c = w[ 4] + MD5C3c;
242 const u32 I_wbc3d = w[11] + MD5C3d;
243 const u32 I_w2c3e = w[ 2] + MD5C3e;
244 const u32 I_w9c3f = w[ 9] + MD5C3f;
252 for (u32 il_pos = 0; il_pos < il_cnt; il_pos += VECT_SIZE)
254 const u32x w0r = words_buf_r[il_pos / VECT_SIZE];
258 w0 = ('o' << 24) + ('e' << 16) + ('h' << 8) + ('t');
265 MD5_STEP (MD5_Fo, a, b, c, d, w0, F_w0c00, MD5S00);
266 MD5_STEP0(MD5_Fo, d, a, b, c, F_w1c01, MD5S01);
267 MD5_STEP0(MD5_Fo, c, d, a, b, F_w2c02, MD5S02);
268 MD5_STEP0(MD5_Fo, b, c, d, a, F_w3c03, MD5S03);
269 MD5_STEP0(MD5_Fo, a, b, c, d, F_w4c04, MD5S00);
270 MD5_STEP0(MD5_Fo, d, a, b, c, F_w5c05, MD5S01);
271 MD5_STEP0(MD5_Fo, c, d, a, b, F_w6c06, MD5S02);
272 MD5_STEP0(MD5_Fo, b, c, d, a, F_w7c07, MD5S03);
273 MD5_STEP0(MD5_Fo, a, b, c, d, F_w8c08, MD5S00);
274 MD5_STEP0(MD5_Fo, d, a, b, c, F_w9c09, MD5S01);
275 MD5_STEP0(MD5_Fo, c, d, a, b, F_wac0a, MD5S02);
276 MD5_STEP0(MD5_Fo, b, c, d, a, F_wbc0b, MD5S03);
277 MD5_STEP0(MD5_Fo, a, b, c, d, F_wcc0c, MD5S00);
278 MD5_STEP0(MD5_Fo, d, a, b, c, F_wdc0d, MD5S01);
279 MD5_STEP0(MD5_Fo, c, d, a, b, F_wec0e, MD5S02);
280 MD5_STEP0(MD5_Fo, b, c, d, a, F_wfc0f, MD5S03);
282 MD5_STEP0(MD5_Go, a, b, c, d, G_w1c10, MD5S10);
283 MD5_STEP0(MD5_Go, d, a, b, c, G_w6c11, MD5S11);
284 MD5_STEP0(MD5_Go, c, d, a, b, G_wbc12, MD5S12);
285 MD5_STEP (MD5_Go, b, c, d, a, w0, G_w0c13, MD5S13);
286 MD5_STEP0(MD5_Go, a, b, c, d, G_w5c14, MD5S10);
287 MD5_STEP0(MD5_Go, d, a, b, c, G_wac15, MD5S11);
288 MD5_STEP0(MD5_Go, c, d, a, b, G_wfc16, MD5S12);
289 MD5_STEP0(MD5_Go, b, c, d, a, G_w4c17, MD5S13);
290 MD5_STEP0(MD5_Go, a, b, c, d, G_w9c18, MD5S10);
291 MD5_STEP0(MD5_Go, d, a, b, c, G_wec19, MD5S11);
292 MD5_STEP0(MD5_Go, c, d, a, b, G_w3c1a, MD5S12);
293 MD5_STEP0(MD5_Go, b, c, d, a, G_w8c1b, MD5S13);
294 MD5_STEP0(MD5_Go, a, b, c, d, G_wdc1c, MD5S10);
295 MD5_STEP0(MD5_Go, d, a, b, c, G_w2c1d, MD5S11);
296 MD5_STEP0(MD5_Go, c, d, a, b, G_w7c1e, MD5S12);
297 MD5_STEP0(MD5_Go, b, c, d, a, G_wcc1f, MD5S13);
299 MD5_STEP0(MD5_H , a, b, c, d, H_w5c20, MD5S20);
300 MD5_STEP0(MD5_H , d, a, b, c, H_w8c21, MD5S21);
301 MD5_STEP0(MD5_H , c, d, a, b, H_wbc22, MD5S22);
302 MD5_STEP0(MD5_H , b, c, d, a, H_wec23, MD5S23);
303 MD5_STEP0(MD5_H , a, b, c, d, H_w1c24, MD5S20);
304 MD5_STEP0(MD5_H , d, a, b, c, H_w4c25, MD5S21);
305 MD5_STEP0(MD5_H , c, d, a, b, H_w7c26, MD5S22);
306 MD5_STEP0(MD5_H , b, c, d, a, H_wac27, MD5S23);
307 MD5_STEP0(MD5_H , a, b, c, d, H_wdc28, MD5S20);
308 MD5_STEP (MD5_H , d, a, b, c, w0, H_w0c29, MD5S21);
309 MD5_STEP0(MD5_H , c, d, a, b, H_w3c2a, MD5S22);
310 MD5_STEP0(MD5_H , b, c, d, a, H_w6c2b, MD5S23);
311 MD5_STEP0(MD5_H , a, b, c, d, H_w9c2c, MD5S20);
312 MD5_STEP0(MD5_H , d, a, b, c, H_wcc2d, MD5S21);
313 MD5_STEP0(MD5_H , c, d, a, b, H_wfc2e, MD5S22);
314 MD5_STEP0(MD5_H , b, c, d, a, H_w2c2f, MD5S23);
316 MD5_STEP (MD5_I , a, b, c, d, w0, I_w0c30, MD5S30);
317 MD5_STEP0(MD5_I , d, a, b, c, I_w7c31, MD5S31);
318 MD5_STEP0(MD5_I , c, d, a, b, I_wec32, MD5S32);
319 MD5_STEP0(MD5_I , b, c, d, a, I_w5c33, MD5S33);
320 MD5_STEP0(MD5_I , a, b, c, d, I_wcc34, MD5S30);
321 MD5_STEP0(MD5_I , d, a, b, c, I_w3c35, MD5S31);
322 MD5_STEP0(MD5_I , c, d, a, b, I_wac36, MD5S32);
323 MD5_STEP0(MD5_I , b, c, d, a, I_w1c37, MD5S33);
324 MD5_STEP0(MD5_I , a, b, c, d, I_w8c38, MD5S30);
325 MD5_STEP0(MD5_I , d, a, b, c, I_wfc39, MD5S31);
326 MD5_STEP0(MD5_I , c, d, a, b, I_w6c3a, MD5S32);
327 MD5_STEP0(MD5_I , b, c, d, a, I_wdc3b, MD5S33);
328 MD5_STEP0(MD5_I , a, b, c, d, I_w4c3c, MD5S30);
329 MD5_STEP0(MD5_I , d, a, b, c, I_wbc3d, MD5S31);
330 MD5_STEP0(MD5_I , c, d, a, b, I_w2c3e, MD5S32);
331 MD5_STEP0(MD5_I , b, c, d, a, I_w9c3f, MD5S33);
333 COMPARE_M_SIMD (a, d, c, b);
337 void m00000s (u32 w[16], const u32 pw_len, __global pw_t *pws, __global kernel_rule_t *rules_buf, __global comb_t *combs_buf, __constant u32x * words_buf_r, __global void *tmps, __global void *hooks, __global u32 *bitmaps_buf_s1_a, __global u32 *bitmaps_buf_s1_b, __global u32 *bitmaps_buf_s1_c, __global u32 *bitmaps_buf_s1_d, __global u32 *bitmaps_buf_s2_a, __global u32 *bitmaps_buf_s2_b, __global u32 *bitmaps_buf_s2_c, __global u32 *bitmaps_buf_s2_d, __global plain_t *plains_buf, __global digest_t *digests_buf, __global u32 *hashes_shown, __global salt_t *salt_bufs, __global void *esalt_bufs, __global u32 *d_return_buf, __global u32 *d_scryptV0_buf, __global u32 *d_scryptV1_buf, __global u32 *d_scryptV2_buf, __global u32 *d_scryptV3_buf, const u32 bitmap_mask, const u32 bitmap_shift1, const u32 bitmap_shift2, const u32 salt_pos, const u32 loop_pos, const u32 loop_cnt, const u32 il_cnt, const u32 digests_cnt, const u32 digests_offset)
343 const u32 gid = get_global_id (0);
344 const u32 lid = get_local_id (0);
350 const u32 F_w0c00 = 0 + MD5C00;
351 const u32 F_w1c01 = w[ 1] + MD5C01;
352 const u32 F_w2c02 = w[ 2] + MD5C02;
353 const u32 F_w3c03 = w[ 3] + MD5C03;
354 const u32 F_w4c04 = w[ 4] + MD5C04;
355 const u32 F_w5c05 = w[ 5] + MD5C05;
356 const u32 F_w6c06 = w[ 6] + MD5C06;
357 const u32 F_w7c07 = w[ 7] + MD5C07;
358 const u32 F_w8c08 = w[ 8] + MD5C08;
359 const u32 F_w9c09 = w[ 9] + MD5C09;
360 const u32 F_wac0a = w[10] + MD5C0a;
361 const u32 F_wbc0b = w[11] + MD5C0b;
362 const u32 F_wcc0c = w[12] + MD5C0c;
363 const u32 F_wdc0d = w[13] + MD5C0d;
364 const u32 F_wec0e = w[14] + MD5C0e;
365 const u32 F_wfc0f = w[15] + MD5C0f;
367 const u32 G_w1c10 = w[ 1] + MD5C10;
368 const u32 G_w6c11 = w[ 6] + MD5C11;
369 const u32 G_wbc12 = w[11] + MD5C12;
370 const u32 G_w0c13 = 0 + MD5C13;
371 const u32 G_w5c14 = w[ 5] + MD5C14;
372 const u32 G_wac15 = w[10] + MD5C15;
373 const u32 G_wfc16 = w[15] + MD5C16;
374 const u32 G_w4c17 = w[ 4] + MD5C17;
375 const u32 G_w9c18 = w[ 9] + MD5C18;
376 const u32 G_wec19 = w[14] + MD5C19;
377 const u32 G_w3c1a = w[ 3] + MD5C1a;
378 const u32 G_w8c1b = w[ 8] + MD5C1b;
379 const u32 G_wdc1c = w[13] + MD5C1c;
380 const u32 G_w2c1d = w[ 2] + MD5C1d;
381 const u32 G_w7c1e = w[ 7] + MD5C1e;
382 const u32 G_wcc1f = w[12] + MD5C1f;
384 const u32 H_w5c20 = w[ 5] + MD5C20;
385 const u32 H_w8c21 = w[ 8] + MD5C21;
386 const u32 H_wbc22 = w[11] + MD5C22;
387 const u32 H_wec23 = w[14] + MD5C23;
388 const u32 H_w1c24 = w[ 1] + MD5C24;
389 const u32 H_w4c25 = w[ 4] + MD5C25;
390 const u32 H_w7c26 = w[ 7] + MD5C26;
391 const u32 H_wac27 = w[10] + MD5C27;
392 const u32 H_wdc28 = w[13] + MD5C28;
393 const u32 H_w0c29 = 0 + MD5C29;
394 const u32 H_w3c2a = w[ 3] + MD5C2a;
395 const u32 H_w6c2b = w[ 6] + MD5C2b;
396 const u32 H_w9c2c = w[ 9] + MD5C2c;
397 const u32 H_wcc2d = w[12] + MD5C2d;
398 const u32 H_wfc2e = w[15] + MD5C2e;
399 const u32 H_w2c2f = w[ 2] + MD5C2f;
401 const u32 I_w0c30 = 0 + MD5C30;
402 const u32 I_w7c31 = w[ 7] + MD5C31;
403 const u32 I_wec32 = w[14] + MD5C32;
404 const u32 I_w5c33 = w[ 5] + MD5C33;
405 const u32 I_wcc34 = w[12] + MD5C34;
406 const u32 I_w3c35 = w[ 3] + MD5C35;
407 const u32 I_wac36 = w[10] + MD5C36;
408 const u32 I_w1c37 = w[ 1] + MD5C37;
409 const u32 I_w8c38 = w[ 8] + MD5C38;
410 const u32 I_wfc39 = w[15] + MD5C39;
411 const u32 I_w6c3a = w[ 6] + MD5C3a;
412 const u32 I_wdc3b = w[13] + MD5C3b;
413 const u32 I_w4c3c = w[ 4] + MD5C3c;
414 const u32 I_wbc3d = w[11] + MD5C3d;
415 const u32 I_w2c3e = w[ 2] + MD5C3e;
416 const u32 I_w9c3f = w[ 9] + MD5C3f;
422 const u32 search[4] =
424 digests_buf[digests_offset].digest_buf[DGST_R0],
425 digests_buf[digests_offset].digest_buf[DGST_R1],
426 digests_buf[digests_offset].digest_buf[DGST_R2],
427 digests_buf[digests_offset].digest_buf[DGST_R3]
434 u32 a_rev = digests_buf[digests_offset].digest_buf[0];
435 u32 b_rev = digests_buf[digests_offset].digest_buf[1];
436 u32 c_rev = digests_buf[digests_offset].digest_buf[2];
437 u32 d_rev = digests_buf[digests_offset].digest_buf[3];
439 MD5_STEP_REV (MD5_I_S, b_rev, c_rev, d_rev, a_rev, w[ 9], MD5C3f, MD5S33);
440 MD5_STEP_REV (MD5_I_S, c_rev, d_rev, a_rev, b_rev, w[ 2], MD5C3e, MD5S32);
441 MD5_STEP_REV (MD5_I_S, d_rev, a_rev, b_rev, c_rev, w[11], MD5C3d, MD5S31);
442 MD5_STEP_REV (MD5_I_S, a_rev, b_rev, c_rev, d_rev, w[ 4], MD5C3c, MD5S30);
443 MD5_STEP_REV (MD5_I_S, b_rev, c_rev, d_rev, a_rev, w[13], MD5C3b, MD5S33);
444 MD5_STEP_REV (MD5_I_S, c_rev, d_rev, a_rev, b_rev, w[ 6], MD5C3a, MD5S32);
445 MD5_STEP_REV (MD5_I_S, d_rev, a_rev, b_rev, c_rev, w[15], MD5C39, MD5S31);
446 MD5_STEP_REV (MD5_I_S, a_rev, b_rev, c_rev, d_rev, w[ 8], MD5C38, MD5S30);
447 MD5_STEP_REV (MD5_I_S, b_rev, c_rev, d_rev, a_rev, w[ 1], MD5C37, MD5S33);
448 MD5_STEP_REV (MD5_I_S, c_rev, d_rev, a_rev, b_rev, w[10], MD5C36, MD5S32);
449 MD5_STEP_REV (MD5_I_S, d_rev, a_rev, b_rev, c_rev, w[ 3], MD5C35, MD5S31);
450 MD5_STEP_REV (MD5_I_S, a_rev, b_rev, c_rev, d_rev, w[12], MD5C34, MD5S30);
451 MD5_STEP_REV (MD5_I_S, b_rev, c_rev, d_rev, a_rev, w[ 5], MD5C33, MD5S33);
452 MD5_STEP_REV (MD5_I_S, c_rev, d_rev, a_rev, b_rev, w[14], MD5C32, MD5S32);
453 MD5_STEP_REV (MD5_I_S, d_rev, a_rev, b_rev, c_rev, w[ 7], MD5C31, MD5S31);
454 MD5_STEP_REV (MD5_I_S, a_rev, b_rev, c_rev, d_rev, 0, MD5C30, MD5S30);
456 const u32 pre_cd = c_rev ^ d_rev;
458 MD5_STEP_REV1(MD5_H_S, b_rev, c_rev, d_rev, a_rev, w[ 2], MD5C2f, MD5S23);
459 MD5_STEP_REV1(MD5_H_S, c_rev, d_rev, a_rev, b_rev, w[15], MD5C2e, MD5S22);
467 for (u32 il_pos = 0; il_pos < il_cnt; il_pos += VECT_SIZE)
469 const u32x w0r = words_buf_r[il_pos / VECT_SIZE];
471 const u32x w0 = w0l | w0r;
473 const u32x pre_d = d_rev;
474 const u32x pre_a = a_rev - w0;
475 const u32x pre_b = b_rev - (pre_a ^ pre_cd);
476 const u32x pre_c = c_rev - (pre_a ^ pre_b ^ pre_d);
483 MD5_STEP (MD5_Fo, a, b, c, d, w0, F_w0c00, MD5S00);
484 MD5_STEP0(MD5_Fo, d, a, b, c, F_w1c01, MD5S01);
485 MD5_STEP0(MD5_Fo, c, d, a, b, F_w2c02, MD5S02);
486 MD5_STEP0(MD5_Fo, b, c, d, a, F_w3c03, MD5S03);
487 MD5_STEP0(MD5_Fo, a, b, c, d, F_w4c04, MD5S00);
488 MD5_STEP0(MD5_Fo, d, a, b, c, F_w5c05, MD5S01);
489 MD5_STEP0(MD5_Fo, c, d, a, b, F_w6c06, MD5S02);
490 MD5_STEP0(MD5_Fo, b, c, d, a, F_w7c07, MD5S03);
491 MD5_STEP0(MD5_Fo, a, b, c, d, F_w8c08, MD5S00);
492 MD5_STEP0(MD5_Fo, d, a, b, c, F_w9c09, MD5S01);
493 MD5_STEP0(MD5_Fo, c, d, a, b, F_wac0a, MD5S02);
494 MD5_STEP0(MD5_Fo, b, c, d, a, F_wbc0b, MD5S03);
495 MD5_STEP0(MD5_Fo, a, b, c, d, F_wcc0c, MD5S00);
496 MD5_STEP0(MD5_Fo, d, a, b, c, F_wdc0d, MD5S01);
497 MD5_STEP0(MD5_Fo, c, d, a, b, F_wec0e, MD5S02);
498 MD5_STEP0(MD5_Fo, b, c, d, a, F_wfc0f, MD5S03);
500 MD5_STEP0(MD5_Go, a, b, c, d, G_w1c10, MD5S10);
501 MD5_STEP0(MD5_Go, d, a, b, c, G_w6c11, MD5S11);
502 MD5_STEP0(MD5_Go, c, d, a, b, G_wbc12, MD5S12);
503 MD5_STEP (MD5_Go, b, c, d, a, w0, G_w0c13, MD5S13);
504 MD5_STEP0(MD5_Go, a, b, c, d, G_w5c14, MD5S10);
505 MD5_STEP0(MD5_Go, d, a, b, c, G_wac15, MD5S11);
506 MD5_STEP0(MD5_Go, c, d, a, b, G_wfc16, MD5S12);
507 MD5_STEP0(MD5_Go, b, c, d, a, G_w4c17, MD5S13);
508 MD5_STEP0(MD5_Go, a, b, c, d, G_w9c18, MD5S10);
509 MD5_STEP0(MD5_Go, d, a, b, c, G_wec19, MD5S11);
510 MD5_STEP0(MD5_Go, c, d, a, b, G_w3c1a, MD5S12);
511 MD5_STEP0(MD5_Go, b, c, d, a, G_w8c1b, MD5S13);
512 MD5_STEP0(MD5_Go, a, b, c, d, G_wdc1c, MD5S10);
513 MD5_STEP0(MD5_Go, d, a, b, c, G_w2c1d, MD5S11);
514 MD5_STEP0(MD5_Go, c, d, a, b, G_w7c1e, MD5S12);
515 MD5_STEP0(MD5_Go, b, c, d, a, G_wcc1f, MD5S13);
517 MD5_STEP0(MD5_H , a, b, c, d, H_w5c20, MD5S20);
518 MD5_STEP0(MD5_H , d, a, b, c, H_w8c21, MD5S21);
519 MD5_STEP0(MD5_H , c, d, a, b, H_wbc22, MD5S22);
520 MD5_STEP0(MD5_H , b, c, d, a, H_wec23, MD5S23);
521 MD5_STEP0(MD5_H , a, b, c, d, H_w1c24, MD5S20);
522 MD5_STEP0(MD5_H , d, a, b, c, H_w4c25, MD5S21);
523 MD5_STEP0(MD5_H , c, d, a, b, H_w7c26, MD5S22);
524 MD5_STEP0(MD5_H , b, c, d, a, H_wac27, MD5S23);
525 MD5_STEP0(MD5_H , a, b, c, d, H_wdc28, MD5S20);
526 MD5_STEP (MD5_H , d, a, b, c, w0, H_w0c29, MD5S21);
527 MD5_STEP0(MD5_H , c, d, a, b, H_w3c2a, MD5S22);
529 if (MATCHES_NONE_VV (pre_c, c)) continue;
531 MD5_STEP0(MD5_H , b, c, d, a, H_w6c2b, MD5S23);
532 MD5_STEP0(MD5_H , a, b, c, d, H_w9c2c, MD5S20);
533 MD5_STEP0(MD5_H , d, a, b, c, H_wcc2d, MD5S21);
535 if (MATCHES_NONE_VV (pre_d, d)) continue;
537 MD5_STEP0(MD5_H , c, d, a, b, H_wfc2e, MD5S22);
538 MD5_STEP0(MD5_H , b, c, d, a, H_w2c2f, MD5S23);
540 MD5_STEP (MD5_I , a, b, c, d, w0, I_w0c30, MD5S30);
541 MD5_STEP0(MD5_I , d, a, b, c, I_w7c31, MD5S31);
542 MD5_STEP0(MD5_I , c, d, a, b, I_wec32, MD5S32);
543 MD5_STEP0(MD5_I , b, c, d, a, I_w5c33, MD5S33);
544 MD5_STEP0(MD5_I , a, b, c, d, I_wcc34, MD5S30);
545 MD5_STEP0(MD5_I , d, a, b, c, I_w3c35, MD5S31);
546 MD5_STEP0(MD5_I , c, d, a, b, I_wac36, MD5S32);
547 MD5_STEP0(MD5_I , b, c, d, a, I_w1c37, MD5S33);
548 MD5_STEP0(MD5_I , a, b, c, d, I_w8c38, MD5S30);
549 MD5_STEP0(MD5_I , d, a, b, c, I_wfc39, MD5S31);
550 MD5_STEP0(MD5_I , c, d, a, b, I_w6c3a, MD5S32);
551 MD5_STEP0(MD5_I , b, c, d, a, I_wdc3b, MD5S33);
552 MD5_STEP0(MD5_I , a, b, c, d, I_w4c3c, MD5S30);
553 MD5_STEP0(MD5_I , d, a, b, c, I_wbc3d, MD5S31);
554 MD5_STEP0(MD5_I , c, d, a, b, I_w2c3e, MD5S32);
555 MD5_STEP0(MD5_I , b, c, d, a, I_w9c3f, MD5S33);
557 COMPARE_S_SIMD (a, d, c, b);
561 __kernel void m00000_m04 (__global pw_t *pws, __global kernel_rule_t *rules_buf, __global comb_t *combs_buf, __constant u32x * words_buf_r, __global void *tmps, __global void *hooks, __global u32 *bitmaps_buf_s1_a, __global u32 *bitmaps_buf_s1_b, __global u32 *bitmaps_buf_s1_c, __global u32 *bitmaps_buf_s1_d, __global u32 *bitmaps_buf_s2_a, __global u32 *bitmaps_buf_s2_b, __global u32 *bitmaps_buf_s2_c, __global u32 *bitmaps_buf_s2_d, __global plain_t *plains_buf, __global digest_t *digests_buf, __global u32 *hashes_shown, __global salt_t *salt_bufs, __global void *esalt_bufs, __global u32 *d_return_buf, __global u32 *d_scryptV0_buf, __global u32 *d_scryptV1_buf, __global u32 *d_scryptV2_buf, __global u32 *d_scryptV3_buf, const u32 bitmap_mask, const u32 bitmap_shift1, const u32 bitmap_shift2, const u32 salt_pos, const u32 loop_pos, const u32 loop_cnt, const u32 il_cnt, const u32 digests_cnt, const u32 digests_offset, const u32 combs_mode, const u32 gid_max)
567 const u32 gid = get_global_id (0);
569 if (gid >= gid_max) return;
573 w[ 0] = pws[gid].i[ 0];
574 w[ 1] = pws[gid].i[ 1];
575 w[ 2] = pws[gid].i[ 2];
576 w[ 3] = pws[gid].i[ 3];
587 w[14] = pws[gid].i[14];
590 const u32 pw_len = pws[gid].pw_len;
596 m00000m (w, pw_len, pws, rules_buf, combs_buf, words_buf_r, tmps, hooks, bitmaps_buf_s1_a, bitmaps_buf_s1_b, bitmaps_buf_s1_c, bitmaps_buf_s1_d, bitmaps_buf_s2_a, bitmaps_buf_s2_b, bitmaps_buf_s2_c, bitmaps_buf_s2_d, plains_buf, digests_buf, hashes_shown, salt_bufs, esalt_bufs, d_return_buf, d_scryptV0_buf, d_scryptV1_buf, d_scryptV2_buf, d_scryptV3_buf, bitmap_mask, bitmap_shift1, bitmap_shift2, salt_pos, loop_pos, loop_cnt, il_cnt, digests_cnt, digests_offset);
599 __kernel void m00000_m08 (__global pw_t *pws, __global kernel_rule_t *rules_buf, __global comb_t *combs_buf, __constant u32x * words_buf_r, __global void *tmps, __global void *hooks, __global u32 *bitmaps_buf_s1_a, __global u32 *bitmaps_buf_s1_b, __global u32 *bitmaps_buf_s1_c, __global u32 *bitmaps_buf_s1_d, __global u32 *bitmaps_buf_s2_a, __global u32 *bitmaps_buf_s2_b, __global u32 *bitmaps_buf_s2_c, __global u32 *bitmaps_buf_s2_d, __global plain_t *plains_buf, __global digest_t *digests_buf, __global u32 *hashes_shown, __global salt_t *salt_bufs, __global void *esalt_bufs, __global u32 *d_return_buf, __global u32 *d_scryptV0_buf, __global u32 *d_scryptV1_buf, __global u32 *d_scryptV2_buf, __global u32 *d_scryptV3_buf, const u32 bitmap_mask, const u32 bitmap_shift1, const u32 bitmap_shift2, const u32 salt_pos, const u32 loop_pos, const u32 loop_cnt, const u32 il_cnt, const u32 digests_cnt, const u32 digests_offset, const u32 combs_mode, const u32 gid_max)
605 const u32 gid = get_global_id (0);
607 if (gid >= gid_max) return;
611 w[ 0] = pws[gid].i[ 0];
612 w[ 1] = pws[gid].i[ 1];
613 w[ 2] = pws[gid].i[ 2];
614 w[ 3] = pws[gid].i[ 3];
615 w[ 4] = pws[gid].i[ 4];
616 w[ 5] = pws[gid].i[ 5];
617 w[ 6] = pws[gid].i[ 6];
618 w[ 7] = pws[gid].i[ 7];
625 w[14] = pws[gid].i[14];
628 const u32 pw_len = pws[gid].pw_len;
634 m00000m (w, pw_len, pws, rules_buf, combs_buf, words_buf_r, tmps, hooks, bitmaps_buf_s1_a, bitmaps_buf_s1_b, bitmaps_buf_s1_c, bitmaps_buf_s1_d, bitmaps_buf_s2_a, bitmaps_buf_s2_b, bitmaps_buf_s2_c, bitmaps_buf_s2_d, plains_buf, digests_buf, hashes_shown, salt_bufs, esalt_bufs, d_return_buf, d_scryptV0_buf, d_scryptV1_buf, d_scryptV2_buf, d_scryptV3_buf, bitmap_mask, bitmap_shift1, bitmap_shift2, salt_pos, loop_pos, loop_cnt, il_cnt, digests_cnt, digests_offset);
637 __kernel void m00000_m16 (__global pw_t *pws, __global kernel_rule_t *rules_buf, __global comb_t *combs_buf, __constant u32x * words_buf_r, __global void *tmps, __global void *hooks, __global u32 *bitmaps_buf_s1_a, __global u32 *bitmaps_buf_s1_b, __global u32 *bitmaps_buf_s1_c, __global u32 *bitmaps_buf_s1_d, __global u32 *bitmaps_buf_s2_a, __global u32 *bitmaps_buf_s2_b, __global u32 *bitmaps_buf_s2_c, __global u32 *bitmaps_buf_s2_d, __global plain_t *plains_buf, __global digest_t *digests_buf, __global u32 *hashes_shown, __global salt_t *salt_bufs, __global void *esalt_bufs, __global u32 *d_return_buf, __global u32 *d_scryptV0_buf, __global u32 *d_scryptV1_buf, __global u32 *d_scryptV2_buf, __global u32 *d_scryptV3_buf, const u32 bitmap_mask, const u32 bitmap_shift1, const u32 bitmap_shift2, const u32 salt_pos, const u32 loop_pos, const u32 loop_cnt, const u32 il_cnt, const u32 digests_cnt, const u32 digests_offset, const u32 combs_mode, const u32 gid_max)
643 const u32 gid = get_global_id (0);
645 if (gid >= gid_max) return;
649 w[ 0] = pws[gid].i[ 0];
650 w[ 1] = pws[gid].i[ 1];
651 w[ 2] = pws[gid].i[ 2];
652 w[ 3] = pws[gid].i[ 3];
653 w[ 4] = pws[gid].i[ 4];
654 w[ 5] = pws[gid].i[ 5];
655 w[ 6] = pws[gid].i[ 6];
656 w[ 7] = pws[gid].i[ 7];
657 w[ 8] = pws[gid].i[ 8];
658 w[ 9] = pws[gid].i[ 9];
659 w[10] = pws[gid].i[10];
660 w[11] = pws[gid].i[11];
661 w[12] = pws[gid].i[12];
662 w[13] = pws[gid].i[13];
663 w[14] = pws[gid].i[14];
664 w[15] = pws[gid].i[15];
666 const u32 pw_len = pws[gid].pw_len;
672 m00000m (w, pw_len, pws, rules_buf, combs_buf, words_buf_r, tmps, hooks, bitmaps_buf_s1_a, bitmaps_buf_s1_b, bitmaps_buf_s1_c, bitmaps_buf_s1_d, bitmaps_buf_s2_a, bitmaps_buf_s2_b, bitmaps_buf_s2_c, bitmaps_buf_s2_d, plains_buf, digests_buf, hashes_shown, salt_bufs, esalt_bufs, d_return_buf, d_scryptV0_buf, d_scryptV1_buf, d_scryptV2_buf, d_scryptV3_buf, bitmap_mask, bitmap_shift1, bitmap_shift2, salt_pos, loop_pos, loop_cnt, il_cnt, digests_cnt, digests_offset);
675 __kernel void m00000_s04 (__global pw_t *pws, __global kernel_rule_t *rules_buf, __global comb_t *combs_buf, __constant u32x * words_buf_r, __global void *tmps, __global void *hooks, __global u32 *bitmaps_buf_s1_a, __global u32 *bitmaps_buf_s1_b, __global u32 *bitmaps_buf_s1_c, __global u32 *bitmaps_buf_s1_d, __global u32 *bitmaps_buf_s2_a, __global u32 *bitmaps_buf_s2_b, __global u32 *bitmaps_buf_s2_c, __global u32 *bitmaps_buf_s2_d, __global plain_t *plains_buf, __global digest_t *digests_buf, __global u32 *hashes_shown, __global salt_t *salt_bufs, __global void *esalt_bufs, __global u32 *d_return_buf, __global u32 *d_scryptV0_buf, __global u32 *d_scryptV1_buf, __global u32 *d_scryptV2_buf, __global u32 *d_scryptV3_buf, const u32 bitmap_mask, const u32 bitmap_shift1, const u32 bitmap_shift2, const u32 salt_pos, const u32 loop_pos, const u32 loop_cnt, const u32 il_cnt, const u32 digests_cnt, const u32 digests_offset, const u32 combs_mode, const u32 gid_max)
681 const u32 gid = get_global_id (0);
683 if (gid >= gid_max) return;
687 w[ 0] = pws[gid].i[ 0];
688 w[ 1] = pws[gid].i[ 1];
689 w[ 2] = pws[gid].i[ 2];
690 w[ 3] = pws[gid].i[ 3];
701 w[14] = pws[gid].i[14];
704 const u32 pw_len = pws[gid].pw_len;
710 m00000s (w, pw_len, pws, rules_buf, combs_buf, words_buf_r, tmps, hooks, bitmaps_buf_s1_a, bitmaps_buf_s1_b, bitmaps_buf_s1_c, bitmaps_buf_s1_d, bitmaps_buf_s2_a, bitmaps_buf_s2_b, bitmaps_buf_s2_c, bitmaps_buf_s2_d, plains_buf, digests_buf, hashes_shown, salt_bufs, esalt_bufs, d_return_buf, d_scryptV0_buf, d_scryptV1_buf, d_scryptV2_buf, d_scryptV3_buf, bitmap_mask, bitmap_shift1, bitmap_shift2, salt_pos, loop_pos, loop_cnt, il_cnt, digests_cnt, digests_offset);
713 __kernel void m00000_s08 (__global pw_t *pws, __global kernel_rule_t *rules_buf, __global comb_t *combs_buf, __constant u32x * words_buf_r, __global void *tmps, __global void *hooks, __global u32 *bitmaps_buf_s1_a, __global u32 *bitmaps_buf_s1_b, __global u32 *bitmaps_buf_s1_c, __global u32 *bitmaps_buf_s1_d, __global u32 *bitmaps_buf_s2_a, __global u32 *bitmaps_buf_s2_b, __global u32 *bitmaps_buf_s2_c, __global u32 *bitmaps_buf_s2_d, __global plain_t *plains_buf, __global digest_t *digests_buf, __global u32 *hashes_shown, __global salt_t *salt_bufs, __global void *esalt_bufs, __global u32 *d_return_buf, __global u32 *d_scryptV0_buf, __global u32 *d_scryptV1_buf, __global u32 *d_scryptV2_buf, __global u32 *d_scryptV3_buf, const u32 bitmap_mask, const u32 bitmap_shift1, const u32 bitmap_shift2, const u32 salt_pos, const u32 loop_pos, const u32 loop_cnt, const u32 il_cnt, const u32 digests_cnt, const u32 digests_offset, const u32 combs_mode, const u32 gid_max)
719 const u32 gid = get_global_id (0);
721 if (gid >= gid_max) return;
725 w[ 0] = pws[gid].i[ 0];
726 w[ 1] = pws[gid].i[ 1];
727 w[ 2] = pws[gid].i[ 2];
728 w[ 3] = pws[gid].i[ 3];
729 w[ 4] = pws[gid].i[ 4];
730 w[ 5] = pws[gid].i[ 5];
731 w[ 6] = pws[gid].i[ 6];
732 w[ 7] = pws[gid].i[ 7];
739 w[14] = pws[gid].i[14];
742 const u32 pw_len = pws[gid].pw_len;
748 m00000s (w, pw_len, pws, rules_buf, combs_buf, words_buf_r, tmps, hooks, bitmaps_buf_s1_a, bitmaps_buf_s1_b, bitmaps_buf_s1_c, bitmaps_buf_s1_d, bitmaps_buf_s2_a, bitmaps_buf_s2_b, bitmaps_buf_s2_c, bitmaps_buf_s2_d, plains_buf, digests_buf, hashes_shown, salt_bufs, esalt_bufs, d_return_buf, d_scryptV0_buf, d_scryptV1_buf, d_scryptV2_buf, d_scryptV3_buf, bitmap_mask, bitmap_shift1, bitmap_shift2, salt_pos, loop_pos, loop_cnt, il_cnt, digests_cnt, digests_offset);
751 __kernel void m00000_s16 (__global pw_t *pws, __global kernel_rule_t *rules_buf, __global comb_t *combs_buf, __constant u32x * words_buf_r, __global void *tmps, __global void *hooks, __global u32 *bitmaps_buf_s1_a, __global u32 *bitmaps_buf_s1_b, __global u32 *bitmaps_buf_s1_c, __global u32 *bitmaps_buf_s1_d, __global u32 *bitmaps_buf_s2_a, __global u32 *bitmaps_buf_s2_b, __global u32 *bitmaps_buf_s2_c, __global u32 *bitmaps_buf_s2_d, __global plain_t *plains_buf, __global digest_t *digests_buf, __global u32 *hashes_shown, __global salt_t *salt_bufs, __global void *esalt_bufs, __global u32 *d_return_buf, __global u32 *d_scryptV0_buf, __global u32 *d_scryptV1_buf, __global u32 *d_scryptV2_buf, __global u32 *d_scryptV3_buf, const u32 bitmap_mask, const u32 bitmap_shift1, const u32 bitmap_shift2, const u32 salt_pos, const u32 loop_pos, const u32 loop_cnt, const u32 il_cnt, const u32 digests_cnt, const u32 digests_offset, const u32 combs_mode, const u32 gid_max)
757 const u32 gid = get_global_id (0);
759 if (gid >= gid_max) return;
763 w[ 0] = pws[gid].i[ 0];
764 w[ 1] = pws[gid].i[ 1];
765 w[ 2] = pws[gid].i[ 2];
766 w[ 3] = pws[gid].i[ 3];
767 w[ 4] = pws[gid].i[ 4];
768 w[ 5] = pws[gid].i[ 5];
769 w[ 6] = pws[gid].i[ 6];
770 w[ 7] = pws[gid].i[ 7];
771 w[ 8] = pws[gid].i[ 8];
772 w[ 9] = pws[gid].i[ 9];
773 w[10] = pws[gid].i[10];
774 w[11] = pws[gid].i[11];
775 w[12] = pws[gid].i[12];
776 w[13] = pws[gid].i[13];
777 w[14] = pws[gid].i[14];
778 w[15] = pws[gid].i[15];
780 const u32 pw_len = pws[gid].pw_len;
786 m00000s (w, pw_len, pws, rules_buf, combs_buf, words_buf_r, tmps, hooks, bitmaps_buf_s1_a, bitmaps_buf_s1_b, bitmaps_buf_s1_c, bitmaps_buf_s1_d, bitmaps_buf_s2_a, bitmaps_buf_s2_b, bitmaps_buf_s2_c, bitmaps_buf_s2_d, plains_buf, digests_buf, hashes_shown, salt_bufs, esalt_bufs, d_return_buf, d_scryptV0_buf, d_scryptV1_buf, d_scryptV2_buf, d_scryptV3_buf, bitmap_mask, bitmap_shift1, bitmap_shift2, salt_pos, loop_pos, loop_cnt, il_cnt, digests_cnt, digests_offset);