Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 18 Feb 2014 18:24:45 +0400
From:      Andrey Chernov <ache@freebsd.org>
To:        Volodymyr Kostyrko <c.kworr@gmail.com>, mm@FreeBSD.org,  Alexander <ags18@yandex.ru>, freebsd-ports@freebsd.org
Subject:   Re: cpuminer mines only on one core regardless of "--threads" option
Message-ID:  <53036D2D.8040401@freebsd.org>
In-Reply-To: <52D541E7.3040305@gmail.com>
References:  <399751389704518@web9j.yandex.ru> <52D541E7.3040305@gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
This is a multi-part message in MIME format.
--------------090903010303030202070909
Content-Type: text/plain; charset=KOI8-R
Content-Transfer-Encoding: 7bit

On 14.01.2014 17:55, Volodymyr Kostyrko wrote:
> 14.01.2014 15:01, Alexander:
>> on Freebsd 9.2 x64 on 5 different PCs I installed net-p2p/cpuminer
>> from ports and by "pkg install" - result is the same - minerd mines
>> only on one core regardless of "--threads" option.

The patch to solve this problem attached.

-- 
http://ache.vniz.net/

--------------090903010303030202070909
Content-Type: text/plain; charset=windows-1251;
 name="patch-cpu-miner.c"
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment;
 filename="patch-cpu-miner.c"

--- cpu-miner.c.bak	2013-07-10 16:00:51.000000000 +0400
+++ cpu-miner.c	2014-02-15 04:40:56.000000000 +0400
@@ -75,7 +75,7 @@
 	cpuset_t set;
 	CPU_ZERO(&set);
 	CPU_SET(cpu, &set);
-	cpuset_setaffinity(CPU_LEVEL_WHICH, CPU_WHICH_CPUSET, -1, sizeof(cpuset_t), &set);
+	cpuset_setaffinity(CPU_LEVEL_WHICH, CPU_WHICH_TID, -1, sizeof(cpuset_t), &set);
 }
 #else
 static inline void drop_policy(void)

--------------090903010303030202070909--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?53036D2D.8040401>