From 1943c35e4ac36d46e3aaba7f640f7717cd6e9ce9 Mon Sep 17 00:00:00 2001 From: Jens Steube Date: Mon, 13 May 2019 17:25:33 +0200 Subject: [PATCH] Improve kernel-loops detection for slow hashes --- src/autotune.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/autotune.c b/src/autotune.c index 11dc8c1d1..42f2b13de 100644 --- a/src/autotune.c +++ b/src/autotune.c @@ -201,7 +201,7 @@ static int autotune (hashcat_ctx_t *hashcat_ctx, hc_device_param_t *device_param if (1) { - const double exec_msec = try_run (hashcat_ctx, device_param, kernel_accel_min, kernel_loops_min); + double exec_msec = try_run (hashcat_ctx, device_param, kernel_accel_min, kernel_loops_min); if (exec_msec > 2000) { @@ -210,6 +210,8 @@ static int autotune (hashcat_ctx_t *hashcat_ctx, hc_device_param_t *device_param return -1; } + exec_msec = try_run (hashcat_ctx, device_param, kernel_accel_min, kernel_loops_min); + const u32 mm = kernel_loops_max / kernel_loops_min; if ((exec_msec * mm) > target_msec)