mirror of
https://github.com/hashcat/hashcat
synced 2025-03-22 21:14:22 +01:00
Use -flegacy-pass-manager for -m 501, -m 1600 and -m 6300 on AMD HIP for massive speed improvement
This commit is contained in:
parent
16d5beb1a6
commit
78ee811fa9
@ -8389,7 +8389,7 @@ static bool load_kernel (hashcat_ctx_t *hashcat_ctx, hc_device_param_t *device_p
|
|||||||
|
|
||||||
hiprtc_options[1] = "-nocudainc";
|
hiprtc_options[1] = "-nocudainc";
|
||||||
hiprtc_options[2] = "-nocudalib";
|
hiprtc_options[2] = "-nocudalib";
|
||||||
hiprtc_options[3] = "";
|
hiprtc_options[3] = "-flegacy-pass-manager";
|
||||||
hiprtc_options[4] = "";
|
hiprtc_options[4] = "";
|
||||||
|
|
||||||
// untested but it should work
|
// untested but it should work
|
||||||
|
@ -59,6 +59,19 @@ u64 module_tmp_size (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSED c
|
|||||||
return tmp_size;
|
return tmp_size;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
char *module_jit_build_options (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSED const user_options_t *user_options, MAYBE_UNUSED const user_options_extra_t *user_options_extra, MAYBE_UNUSED const hashes_t *hashes, MAYBE_UNUSED const hc_device_param_t *device_param)
|
||||||
|
{
|
||||||
|
char *jit_build_options = NULL;
|
||||||
|
|
||||||
|
// AMD HIP
|
||||||
|
if (device_param->opencl_device_vendor_id == VENDOR_ID_AMD_USE_HIP)
|
||||||
|
{
|
||||||
|
hc_asprintf (&jit_build_options, "-flegacy-pass-manager");
|
||||||
|
}
|
||||||
|
|
||||||
|
return jit_build_options;
|
||||||
|
}
|
||||||
|
|
||||||
static void AES128_decrypt_cbc (const u32 key[4], const u32 iv[4], const u32 in[16], u32 out[16])
|
static void AES128_decrypt_cbc (const u32 key[4], const u32 iv[4], const u32 in[16], u32 out[16])
|
||||||
{
|
{
|
||||||
AES_KEY skey;
|
AES_KEY skey;
|
||||||
@ -370,7 +383,7 @@ void module_init (module_ctx_t *module_ctx)
|
|||||||
module_ctx->module_hook23 = MODULE_DEFAULT;
|
module_ctx->module_hook23 = MODULE_DEFAULT;
|
||||||
module_ctx->module_hook_salt_size = MODULE_DEFAULT;
|
module_ctx->module_hook_salt_size = MODULE_DEFAULT;
|
||||||
module_ctx->module_hook_size = MODULE_DEFAULT;
|
module_ctx->module_hook_size = MODULE_DEFAULT;
|
||||||
module_ctx->module_jit_build_options = MODULE_DEFAULT;
|
module_ctx->module_jit_build_options = module_jit_build_options;
|
||||||
module_ctx->module_jit_cache_disable = MODULE_DEFAULT;
|
module_ctx->module_jit_cache_disable = MODULE_DEFAULT;
|
||||||
module_ctx->module_kernel_accel_max = MODULE_DEFAULT;
|
module_ctx->module_kernel_accel_max = MODULE_DEFAULT;
|
||||||
module_ctx->module_kernel_accel_min = MODULE_DEFAULT;
|
module_ctx->module_kernel_accel_min = MODULE_DEFAULT;
|
||||||
|
@ -57,6 +57,19 @@ u64 module_tmp_size (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSED c
|
|||||||
return tmp_size;
|
return tmp_size;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
char *module_jit_build_options (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSED const user_options_t *user_options, MAYBE_UNUSED const user_options_extra_t *user_options_extra, MAYBE_UNUSED const hashes_t *hashes, MAYBE_UNUSED const hc_device_param_t *device_param)
|
||||||
|
{
|
||||||
|
char *jit_build_options = NULL;
|
||||||
|
|
||||||
|
// AMD HIP
|
||||||
|
if (device_param->opencl_device_vendor_id == VENDOR_ID_AMD_USE_HIP)
|
||||||
|
{
|
||||||
|
hc_asprintf (&jit_build_options, "-flegacy-pass-manager");
|
||||||
|
}
|
||||||
|
|
||||||
|
return jit_build_options;
|
||||||
|
}
|
||||||
|
|
||||||
static void md5crypt_decode (u8 digest[16], const u8 buf[22])
|
static void md5crypt_decode (u8 digest[16], const u8 buf[22])
|
||||||
{
|
{
|
||||||
int l;
|
int l;
|
||||||
@ -291,7 +304,7 @@ void module_init (module_ctx_t *module_ctx)
|
|||||||
module_ctx->module_hook23 = MODULE_DEFAULT;
|
module_ctx->module_hook23 = MODULE_DEFAULT;
|
||||||
module_ctx->module_hook_salt_size = MODULE_DEFAULT;
|
module_ctx->module_hook_salt_size = MODULE_DEFAULT;
|
||||||
module_ctx->module_hook_size = MODULE_DEFAULT;
|
module_ctx->module_hook_size = MODULE_DEFAULT;
|
||||||
module_ctx->module_jit_build_options = MODULE_DEFAULT;
|
module_ctx->module_jit_build_options = module_jit_build_options;
|
||||||
module_ctx->module_jit_cache_disable = MODULE_DEFAULT;
|
module_ctx->module_jit_cache_disable = MODULE_DEFAULT;
|
||||||
module_ctx->module_kernel_accel_max = MODULE_DEFAULT;
|
module_ctx->module_kernel_accel_max = MODULE_DEFAULT;
|
||||||
module_ctx->module_kernel_accel_min = MODULE_DEFAULT;
|
module_ctx->module_kernel_accel_min = MODULE_DEFAULT;
|
||||||
|
@ -57,6 +57,19 @@ u64 module_tmp_size (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSED c
|
|||||||
return tmp_size;
|
return tmp_size;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
char *module_jit_build_options (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSED const user_options_t *user_options, MAYBE_UNUSED const user_options_extra_t *user_options_extra, MAYBE_UNUSED const hashes_t *hashes, MAYBE_UNUSED const hc_device_param_t *device_param)
|
||||||
|
{
|
||||||
|
char *jit_build_options = NULL;
|
||||||
|
|
||||||
|
// AMD HIP
|
||||||
|
if (device_param->opencl_device_vendor_id == VENDOR_ID_AMD_USE_HIP)
|
||||||
|
{
|
||||||
|
hc_asprintf (&jit_build_options, "-flegacy-pass-manager");
|
||||||
|
}
|
||||||
|
|
||||||
|
return jit_build_options;
|
||||||
|
}
|
||||||
|
|
||||||
static void md5crypt_decode (u8 digest[16], const u8 buf[22])
|
static void md5crypt_decode (u8 digest[16], const u8 buf[22])
|
||||||
{
|
{
|
||||||
int l;
|
int l;
|
||||||
@ -282,7 +295,7 @@ void module_init (module_ctx_t *module_ctx)
|
|||||||
module_ctx->module_hook23 = MODULE_DEFAULT;
|
module_ctx->module_hook23 = MODULE_DEFAULT;
|
||||||
module_ctx->module_hook_salt_size = MODULE_DEFAULT;
|
module_ctx->module_hook_salt_size = MODULE_DEFAULT;
|
||||||
module_ctx->module_hook_size = MODULE_DEFAULT;
|
module_ctx->module_hook_size = MODULE_DEFAULT;
|
||||||
module_ctx->module_jit_build_options = MODULE_DEFAULT;
|
module_ctx->module_jit_build_options = module_jit_build_options;
|
||||||
module_ctx->module_jit_cache_disable = MODULE_DEFAULT;
|
module_ctx->module_jit_cache_disable = MODULE_DEFAULT;
|
||||||
module_ctx->module_kernel_accel_max = MODULE_DEFAULT;
|
module_ctx->module_kernel_accel_max = MODULE_DEFAULT;
|
||||||
module_ctx->module_kernel_accel_min = MODULE_DEFAULT;
|
module_ctx->module_kernel_accel_min = MODULE_DEFAULT;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user