genesismining / sgminer-gm

A multi-algo GPU miner
GNU General Public License v3.0
339 stars 146 forks source link

Adapt block handling for multiple pools #8

Open keithdunnett opened 7 years ago

keithdunnett commented 7 years ago

sgminer's handling of network blocks does odd things when using multiple pools for Ethereum. Most notably in reporting blocks found; finding a block for any pool will log a block found against most or all of the pools in use, often multiple times.

Side effect is that it can spend a minute or two exclaiming recursively that it found a block and assuming there's no other work to be done. I'm not a programmer or adequately familiar with the code, but superficially it would seem that some of the block handling is done per rig and not per pool.

Besides yielding some unlikely statistics:

"Elapsed": 12495, "Found Blocks": 646, "Network Blocks": 3653,

this can leave the rig in limbo normally for a few seconds but sometimes for a minute or two, which must impact on overall work output. Where a rig receives stratum work from multiple pools on different blocks, there is room for more gracious handling.

An example of what happens presently:

[13:56:51] Accepted 6b43076f Diff 547M/422M BLOCK! GPU 4 at pool.alpereum.ch [13:56:52] Found block for pool.alpereum.ch! [13:56:52] Found block for pool.alpereum.ch! [13:56:52] Found block for pool.alpereum.ch! [13:56:53] Found block for us1.ethermine.org! [13:56:53] Found block for pool.alpereum.ch! [13:56:53] Found block for pool.alpereum.ch! [13:56:53] Found block for us1.ethermine.org! [13:56:54] Found block for eth-eu2.nanopool.org!

(and more of the same).

Sutasu-sama commented 6 years ago

Hello. Is there any fix to this?