CPU affinity is not working as expected (by me
) on dual Xeon E5-2460v3 on Windows 2012 R2
I want to use only 1 thread per physical core on both the CPUs, but I'm not able to do it.
I'm testing v3.7.9 with the following cmd line:
cpuminer-aes-avx2 -a lbry -t 16 --cpu-affinity 0xAAAAAAAA [...]
I'd like to spread the threads over the 16 available physical cores, but I'm only able to saturate 16 logical processor of the first CPU:
http://i68.tinypic.com/saupo5.pngNo matter what I set in the affinity option, I always obtain the same result.
If I start cpuminer with "-t 1" I get 526 kH/s per CPU, when I start it with "-t 16" I obtain only 249 kH/s per CPU.
On a single CPU system with 8 cores and 16 logical cpu, I'm able to obtain exactly what I want with affinity.
Like the pevious guy you're creating a problem where there is none. Use the default affinity and don't make assumptions.
If you want to see which physical cores are working look at their temperature.
If you have a problem after that post debug output.
I already tried to use default affinity and I got the same result.
I'll check temperature and I'll report the result.
But if my assumption is wrong, why single thread has double rate x CPU than multi-threads?
Beside that, thank you for your great piece of software and for your attention.
--- EDIT ---
My assumption is confirmed by HWMonitor
http://i68.tinypic.com/4jt2xv.png http://i68.tinypic.com/rvixom.png--- EDIT2 ---
Here's the output with debug enabled
C:\Program Files\cpumin>cpuminer-aes-avx2 -a lbry -t 16 -D -o stratum+tcp://xxxx -u xxxx -p xxxx
********** cpuminer-opt 3.7.9 ***********
A CPU miner with multi algo support and optimized for CPUs
with AES_NI and AVX2 and SHA extensions.
BTC donation address: 12tdvfF7KmAsihBXQXynT6E6th2c2pByTT
CPU: Intel(R) Xeon(R) CPU E5-2640 v3 @ 2.60GHz.
SW built on Jan 8 2018 with GCC 5.3.1.
CPU features: SSE2 AES AVX AVX2.
SW features: SSE2 AES AVX AVX2.
Algo features: SSE2 AVX AVX2 SHA.
Start mining with AVX2.
[2018-01-12 10:31:44] Binding thread 13 to cpu 13 (mask 2000)
[2018-01-12 10:31:44] Starting Stratum on stratum+tcp://xxxx
[2018-01-12 10:31:44] Binding thread 0 to cpu 0 (mask 1)
[2018-01-12 10:31:44] Binding thread 14 to cpu 14 (mask 4000)
[2018-01-12 10:31:44] Binding thread 1 to cpu 1 (mask 2)
[2018-01-12 10:31:44] Binding thread 2 to cpu 2 (mask 4)
[2018-01-12 10:31:44] Binding thread 3 to cpu 3 (mask 8)
[2018-01-12 10:31:44] Binding thread 4 to cpu 4 (mask 10)
[2018-01-12 10:31:44] Binding thread 5 to cpu 5 (mask 20)
[2018-01-12 10:31:44] Binding thread 6 to cpu 6 (mask 40)
[2018-01-12 10:31:44] Binding thread 7 to cpu 7 (mask 80)
[2018-01-12 10:31:44] 16 miner threads started, using 'lbry' algorithm.
[2018-01-12 10:31:44] Binding thread 8 to cpu 8 (mask 100)
[2018-01-12 10:31:44] Binding thread 9 to cpu 9 (mask 200)
[2018-01-12 10:31:44] Binding thread 15 to cpu 15 (mask 8000)
[2018-01-12 10:31:44] Binding thread 10 to cpu 10 (mask 400)
[2018-01-12 10:31:44] Binding thread 11 to cpu 11 (mask 800)
[2018-01-12 10:31:44] Binding thread 12 to cpu 12 (mask 1000)
[2018-01-12 10:31:44] Stratum session id: deadbeefcafebabe8681430000000000
[2018-01-12 10:31:44] Stratum difficulty set to 256
[2018-01-12 10:31:47] stratum extranonce subscribe timed out
[2018-01-12 10:31:47] DEBUG: job_id='34b9' extranonce2=00000000 ntime=1f24d637
[2018-01-12 10:31:47] xxxx asks job 13497 for block 303984
[2018-01-12 10:31:48] CPU #6: 131.07 kH, 158.28 kH/s
[2018-01-12 10:31:48] CPU #7: 131.07 kH, 158.28 kH/s
[2018-01-12 10:31:48] CPU #14: 131.07 kH, 158.28 kH/s
[2018-01-12 10:31:48] CPU #1: 131.07 kH, 158.28 kH/s
[2018-01-12 10:31:48] CPU #0: 131.07 kH, 158.28 kH/s
[2018-01-12 10:31:48] CPU #15: 131.07 kH, 158.28 kH/s
[2018-01-12 10:31:48] CPU #9: 131.07 kH, 158.28 kH/s
[2018-01-12 10:31:48] CPU #8: 131.07 kH, 158.28 kH/s
[2018-01-12 10:31:48] CPU #13: 131.07 kH, 158.28 kH/s
[2018-01-12 10:31:48] CPU #12: 131.07 kH, 158.28 kH/s
[2018-01-12 10:31:48] CPU #3: 131.07 kH, 158.28 kH/s
[2018-01-12 10:31:48] CPU #2: 131.07 kH, 158.28 kH/s
[2018-01-12 10:31:48] CPU #5: 131.07 kH, 158.28 kH/s
[2018-01-12 10:31:48] CPU #4: 131.07 kH, 158.28 kH/s
[2018-01-12 10:31:48] CPU #11: 131.07 kH, 158.28 kH/s
[2018-01-12 10:31:48] CPU #10: 131.07 kH, 158.28 kH/s
[2018-01-12 10:31:51] DEBUG: job_id='34ba' extranonce2=00000000 ntime=1f24d637
[2018-01-12 10:31:51] lbry block 303985, diff 427620.506
[2018-01-12 10:31:51] CPU #0: 707.05 kH, 243.28 kH/s
[2018-01-12 10:31:51] CPU #6: 706.87 kH, 243.22 kH/s
[2018-01-12 10:31:51] CPU #5: 706.71 kH, 243.17 kH/s
[2018-01-12 10:31:51] CPU #10: 706.25 kH, 244.32 kH/s
[2018-01-12 10:31:51] CPU #7: 706.67 kH, 243.15 kH/s
[2018-01-12 10:31:51] CPU #8: 705.90 kH, 242.89 kH/s
[2018-01-12 10:31:51] CPU #4: 706.64 kH, 243.14 kH/s
[2018-01-12 10:31:51] CPU #13: 706.68 kH, 243.16 kH/s
[2018-01-12 10:31:51] CPU #1: 707.15 kH, 243.32 kH/s
[2018-01-12 10:31:51] CPU #3: 704.80 kH, 242.51 kH/s
[2018-01-12 10:31:51] CPU #2: 704.64 kH, 242.45 kH/s
[2018-01-12 10:31:51] CPU #11: 706.47 kH, 243.08 kH/s
[2018-01-12 10:31:51] CPU #14: 706.79 kH, 243.19 kH/s
[2018-01-12 10:31:51] CPU #12: 706.55 kH, 243.11 kH/s
[2018-01-12 10:31:51] CPU #9: 706.03 kH, 242.93 kH/s
[2018-01-12 10:31:51] CPU #15: 706.02 kH, 242.93 kH/s
[2018-01-12 10:32:46] DEBUG: job_id='34bb' extranonce2=00000000 ntime=1f24d637
[2018-01-12 10:32:46] xxxx asks job 13499 for block 303985
[2018-01-12 10:32:50] CPU #2: 14.55 MH, 249.27 kH/s
[2018-01-12 10:32:50] CPU #8: 14.57 MH, 249.31 kH/s
[2018-01-12 10:32:50] CPU #1: 14.60 MH, 249.55 kH/s
[2018-01-12 10:32:50] CPU #11: 14.59 MH, 249.31 kH/s
[2018-01-12 10:32:50] CPU #15: 14.58 MH, 249.16 kH/s
[2018-01-12 10:32:50] CPU #12: 14.59 MH, 249.28 kH/s
[2018-01-12 10:32:50] CPU #3: 14.55 MH, 248.66 kH/s
[2018-01-12 10:32:50] CPU #14: 14.59 MH, 249.36 kH/s
[2018-01-12 10:32:50] CPU #13: 14.59 MH, 249.32 kH/s
[2018-01-12 10:32:50] CPU #5: 14.59 MH, 249.33 kH/s
[2018-01-12 10:32:50] CPU #7: 14.59 MH, 249.32 kH/s
[2018-01-12 10:32:50] CPU #6: 14.59 MH, 249.39 kH/s
[2018-01-12 10:32:50] CPU #4: 14.59 MH, 249.24 kH/s
[2018-01-12 10:32:50] CPU #9: 14.58 MH, 248.30 kH/s
[2018-01-12 10:32:50] CPU #0: 14.60 MH, 248.52 kH/s
[2018-01-12 10:32:50] CPU #10: 14.66 MH, 249.45 kH/s
[2018-01-12 10:33:42] DEBUG: job_id='34bc' extranonce2=00000000 ntime=1f24d637
[2018-01-12 10:33:42] xxxx asks job 13500 for block 303985
...