1
0
mirror of https://github.com/GOSTSec/sgminer synced 2025-03-09 20:21:01 +00:00

Simplify the enough work algorithm dramatically.

This commit is contained in:
Con Kolivas 2012-08-16 17:24:04 +10:00
parent 0e56dffd92
commit b60f9da4a5

View File

@ -2408,9 +2408,13 @@ static void *get_work_thread(void *userdata)
ts = __total_staged();
mutex_unlock(stgd_lock);
if (((cs >= opt_queue || cq >= opt_queue) && ts >= maxq) ||
((cs >= opt_queue || cq >= opt_queue) && tq >= maxq && ((cq < maxq && !opt_fail_only) || opt_fail_only)) ||
clone_available())
if (ts >= maxq)
goto out;
if (ts >= opt_queue && tq >= maxq)
goto out;
if (clone_available())
goto out;
ret_work = make_work();