mirror of
https://github.com/hashcat/hashcat.git
synced 2025-07-07 07:12:36 +00:00
Limit -T maximum on -m 3200 to what's possible based on device specific shared memory available
This commit is contained in:
parent
d67de66453
commit
200e72dba3
@ -93,12 +93,6 @@ char *module_jit_build_options (MAYBE_UNUSED const hashconfig_t *hashconfig, MAY
|
|||||||
fixed_local_size = 1;
|
fixed_local_size = 1;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
|
||||||
if (user_options->kernel_threads_chgd == true)
|
|
||||||
{
|
|
||||||
fixed_local_size = user_options->kernel_threads;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
{
|
||||||
u32 overhead = 0;
|
u32 overhead = 0;
|
||||||
|
|
||||||
@ -113,6 +107,19 @@ char *module_jit_build_options (MAYBE_UNUSED const hashconfig_t *hashconfig, MAY
|
|||||||
overhead = 4;
|
overhead = 4;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (user_options->kernel_threads_chgd == true)
|
||||||
|
{
|
||||||
|
fixed_local_size = user_options->kernel_threads;
|
||||||
|
|
||||||
|
// otherwise out-of-bound reads
|
||||||
|
|
||||||
|
if ((fixed_local_size * 4096) > (device_param->device_local_mem_size - overhead))
|
||||||
|
{
|
||||||
|
fixed_local_size = (device_param->device_local_mem_size - overhead) / 4096;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
fixed_local_size = (device_param->device_local_mem_size - overhead) / 4096;
|
fixed_local_size = (device_param->device_local_mem_size - overhead) / 4096;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user