Skip to content

Commit

Permalink
fix sizes of vars
Browse files Browse the repository at this point in the history
  • Loading branch information
NaN-git committed Sep 6, 2016
1 parent 7824ae1 commit 64f46cd
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions algorithm.c
Original file line number Diff line number Diff line change
Expand Up @@ -971,7 +971,7 @@ static cl_int queue_ethash_kernel(_clState *clState, dev_blk_ctx *blk, __maybe_u
cl_ulong le_target;
cl_uint HighNonce, Isolate = 0xFFFFFFFFUL;
cl_ulong DAGSize = EthGetDAGSize(blk->work->EpochNumber);
cl_uint DAGItems = (cl_uint)(DAGSize / 64);
size_t DAGItems = (size_t) (DAGSize / 64);

le_target = *(cl_ulong *)(blk->work->device_target + 24);

Expand Down Expand Up @@ -1057,12 +1057,12 @@ static cl_int queue_ethash_kernel(_clState *clState, dev_blk_ctx *blk, __maybe_u
kernel = &clState->kernel;

// Not nodes now (64 bytes), but DAG entries (128 bytes)
DAGItems >>= 1;
cl_uint ItemsArg = DAGItems >> 1;

CL_SET_ARG(clState->outputBuffer);
CL_SET_ARG(clState->CLbuffer0);
CL_SET_ARG(clState->DAG);
CL_SET_ARG(DAGItems);
CL_SET_ARG(ItemsArg);
CL_SET_ARG(blk->work->Nonce);
CL_SET_ARG(le_target);
CL_SET_ARG(Isolate);
Expand Down

0 comments on commit 64f46cd

Please sign in to comment.