mirror of
https://github.com/GOSTSec/sgminer
synced 2025-02-04 11:04:26 +00:00
Check that all threads on the device that called get_work are waiting on getwork before considering the pool lagging.
This commit is contained in:
parent
44f5d55d51
commit
b0de3edeb8
19
cgminer.c
19
cgminer.c
@ -3632,12 +3632,27 @@ retry:
|
|||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (requested && !newreq && !requests_staged() && requests_queued() >= mining_threads &&
|
if (!pool->lagging && requested && !newreq && !requests_staged() && requests_queued() >= mining_threads) {
|
||||||
!pool_tset(pool, &pool->lagging)) {
|
struct cgpu_info *cgpu = thr->cgpu;
|
||||||
|
bool stalled = true;
|
||||||
|
int i;
|
||||||
|
|
||||||
|
/* Check to see if all the threads on the device that called
|
||||||
|
* get_work are waiting on work and only consider the pool
|
||||||
|
* lagging if true */
|
||||||
|
for (i = 0; i < cgpu->threads; i++) {
|
||||||
|
if (!cgpu->thr[i]->getwork) {
|
||||||
|
stalled = false;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (stalled && !pool_tset(pool, &pool->lagging)) {
|
||||||
applog(LOG_WARNING, "Pool %d not providing work fast enough", pool->pool_no);
|
applog(LOG_WARNING, "Pool %d not providing work fast enough", pool->pool_no);
|
||||||
pool->getfail_occasions++;
|
pool->getfail_occasions++;
|
||||||
total_go++;
|
total_go++;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
newreq = requested = false;
|
newreq = requested = false;
|
||||||
gettimeofday(&now, NULL);
|
gettimeofday(&now, NULL);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user