Skip to content
Snippets Groups Projects
Commit d326644d authored by psychocrypt's avatar psychocrypt
Browse files

fix nvidia auto suggestion

The lmem is still incalculably and crash the miner very often.
Increase the potential lmem usage to 16kiB to respect lmem alignments, ...
parent 51c7b26e
No related branches found
No related tags found
No related merge requests found
......@@ -467,9 +467,9 @@ extern "C" int cuda_get_deviceinfo(nvid_ctx* ctx)
// 200byte are meta data memory (result nonce, ...)
size_t availableMem = freeMemory - (128u * byteToMiB) - 200u;
size_t limitedMemory = std::min(availableMem, maxMemUsage);
// up to 1kibyte extra memory is used per thread for some kernel (lmem/local memory)
// up to 16kibyte extra memory is used per thread for some kernel (lmem/local memory)
// 680bytes are extra meta data memory per hash
size_t perThread = hashMemSize + 1024u + 680u;
size_t perThread = hashMemSize + 16192u + 680u;
size_t max_intensity = limitedMemory / perThread;
ctx->device_threads = max_intensity / ctx->device_blocks;
// use only odd number of threads
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment