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

fix assert in AMD backend

fix bug announced in #52

If the miner is compiled in debug mode the assert condition results in a compile time error.
parent 6701b0c2
No related branches found
No related tags found
No related merge requests found
......@@ -896,7 +896,7 @@ size_t XMRRunJob(GpuContext* ctx, cl_uint* HashOutput)
// round up to next multiple of w_size
BranchNonces[i] = ((BranchNonces[i] + w_size - 1u) / w_size) * w_size;
// number of global threads must be a multiple of the work group size (w_size)
assert(BranchNonces%w_size == 0);
assert(BranchNonces[i]%w_size == 0);
if((ret = clEnqueueNDRangeKernel(ctx->CommandQueues, ctx->Kernels[i + 3], 1, &ctx->Nonce, BranchNonces + i, &w_size, 0, NULL, NULL)) != CL_SUCCESS)
{
printer::inst()->print_msg(L1,"Error %s when calling clEnqueueNDRangeKernel for kernel %d.", err_to_str(ret), i + 3);
......
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