1
0
mirror of https://github.com/GOSTSec/sgminer synced 2025-01-11 15:27:53 +00:00

Revert "Revert "Since we roll work all the time now, we end up staging a lot of work without queueing, so don't queue if we've already got staged work.""

This reverts commit cea1cf6cc0.

This wasn't eht cause of the false positives.
This commit is contained in:
Con Kolivas 2011-08-24 23:34:22 +10:00
parent cea1cf6cc0
commit f2f0ba8024

4
main.c
View File

@ -2945,6 +2945,9 @@ static bool queue_request(struct thr_info *thr, bool needed)
if (rq >= maxq || rs >= maxq) if (rq >= maxq || rs >= maxq)
return true; return true;
if (rs > rq)
goto out;
/* fill out work request message */ /* fill out work request message */
wc = calloc(1, sizeof(*wc)); wc = calloc(1, sizeof(*wc));
if (unlikely(!wc)) { if (unlikely(!wc)) {
@ -2973,6 +2976,7 @@ static bool queue_request(struct thr_info *thr, bool needed)
workio_cmd_free(wc); workio_cmd_free(wc);
return false; return false;
} }
out:
inc_queued(); inc_queued();
return true; return true;
} }