mirror of
https://github.com/GOSTSec/sgminer
synced 2025-01-10 23:08:07 +00:00
Walk through the thread list instead of searching for them when disabling threads for dynamic mode.
This commit is contained in:
parent
6a45cbbdfb
commit
eb36f8d271
@ -538,15 +538,11 @@ struct cgpu_info *cpus;
|
|||||||
void pause_dynamic_threads(int gpu)
|
void pause_dynamic_threads(int gpu)
|
||||||
{
|
{
|
||||||
struct cgpu_info *cgpu = &gpus[gpu];
|
struct cgpu_info *cgpu = &gpus[gpu];
|
||||||
int i, thread_no = 0;
|
int i;
|
||||||
|
|
||||||
for (i = 0; i < mining_threads; i++) {
|
for (i = 1; i < cgpu->threads; i++) {
|
||||||
struct thr_info *thr = &thr_info[i];
|
struct thr_info *thr = &thr_info[i];
|
||||||
|
|
||||||
if (thr->cgpu != cgpu)
|
|
||||||
continue;
|
|
||||||
if (!thread_no++)
|
|
||||||
continue;
|
|
||||||
if (!thr->pause && cgpu->dynamic) {
|
if (!thr->pause && cgpu->dynamic) {
|
||||||
applog(LOG_WARNING, "Disabling extra threads due to dynamic mode.");
|
applog(LOG_WARNING, "Disabling extra threads due to dynamic mode.");
|
||||||
applog(LOG_WARNING, "Tune dynamic intensity with --gpu-dyninterval");
|
applog(LOG_WARNING, "Tune dynamic intensity with --gpu-dyninterval");
|
||||||
|
Loading…
Reference in New Issue
Block a user