diff --git a/OpenCL/m01100_a3-pure.cl b/OpenCL/m01100_a3-pure.cl index 643bd0cef..afa425501 100644 --- a/OpenCL/m01100_a3-pure.cl +++ b/OpenCL/m01100_a3-pure.cl @@ -61,6 +61,33 @@ KERNEL_FQ void m01100_mxx (KERN_ATTR_VECTOR ()) w[0] = w0; + #if VECT_SIZE == 1 + + md4_ctx_t ctx0; + + md4_init (&ctx0); + + md4_update_utf16le (&ctx0, w, pw_len); + + md4_final (&ctx0); + + md4_ctx_t ctx; + + md4_init (&ctx); + + ctx.w0[0] = ctx0.h[0]; + ctx.w0[1] = ctx0.h[1]; + ctx.w0[2] = ctx0.h[2]; + ctx.w0[3] = ctx0.h[3]; + + ctx.len = 16; + + md4_update_utf16le (&ctx, s, salt_len); + + md4_final (&ctx); + + #else + md4_ctx_vector_t ctx0; md4_init_vector (&ctx0); @@ -84,6 +111,8 @@ KERNEL_FQ void m01100_mxx (KERN_ATTR_VECTOR ()) md4_final_vector (&ctx); + #endif + const u32x r0 = ctx.h[DGST_R0]; const u32x r1 = ctx.h[DGST_R1]; const u32x r2 = ctx.h[DGST_R2]; @@ -152,6 +181,33 @@ KERNEL_FQ void m01100_sxx (KERN_ATTR_VECTOR ()) w[0] = w0; + #if VECT_SIZE == 1 + + md4_ctx_t ctx0; + + md4_init (&ctx0); + + md4_update_utf16le (&ctx0, w, pw_len); + + md4_final (&ctx0); + + md4_ctx_t ctx; + + md4_init (&ctx); + + ctx.w0[0] = ctx0.h[0]; + ctx.w0[1] = ctx0.h[1]; + ctx.w0[2] = ctx0.h[2]; + ctx.w0[3] = ctx0.h[3]; + + ctx.len = 16; + + md4_update_utf16le (&ctx, s, salt_len); + + md4_final (&ctx); + + #else + md4_ctx_vector_t ctx0; md4_init_vector (&ctx0); @@ -175,6 +231,8 @@ KERNEL_FQ void m01100_sxx (KERN_ATTR_VECTOR ()) md4_final_vector (&ctx); + #endif + const u32x r0 = ctx.h[DGST_R0]; const u32x r1 = ctx.h[DGST_R1]; const u32x r2 = ctx.h[DGST_R2]; diff --git a/OpenCL/m05500_a3-pure.cl b/OpenCL/m05500_a3-pure.cl index 3ef7460da..ab19a80bc 100644 --- a/OpenCL/m05500_a3-pure.cl +++ b/OpenCL/m05500_a3-pure.cl @@ -586,6 +586,18 @@ KERNEL_FQ void m05500_mxx (KERN_ATTR_VECTOR ()) w[0] = w0; + #if VECT_SIZE == 1 + + md4_ctx_t ctx; + + md4_init (&ctx); + + md4_update_utf16le (&ctx, w, pw_len); + + md4_final (&ctx); + + #else + md4_ctx_vector_t ctx; md4_init_vector (&ctx); @@ -594,6 +606,8 @@ KERNEL_FQ void m05500_mxx (KERN_ATTR_VECTOR ()) md4_final_vector (&ctx); + #endif + const u32x a = ctx.h[0]; const u32x b = ctx.h[1]; const u32x c = ctx.h[2]; @@ -742,6 +756,18 @@ KERNEL_FQ void m05500_sxx (KERN_ATTR_VECTOR ()) w[0] = w0; + #if VECT_SIZE == 1 + + md4_ctx_t ctx; + + md4_init (&ctx); + + md4_update_utf16le (&ctx, w, pw_len); + + md4_final (&ctx); + + #else + md4_ctx_vector_t ctx; md4_init_vector (&ctx); @@ -750,6 +776,8 @@ KERNEL_FQ void m05500_sxx (KERN_ATTR_VECTOR ()) md4_final_vector (&ctx); + #endif + const u32x a = ctx.h[0]; const u32x b = ctx.h[1]; const u32x c = ctx.h[2];