lucasjones / cpuminer-multi

Multi-algo CPUMiner & Reference Cryptonote Miner (JSON-RPC 2.0)
Other
635 stars 1.49k forks source link

Please add the new / Forked Algo Support - CN-AscendingNight #109

Open Cideg opened 5 years ago

Cideg commented 5 years ago

Tax-Project uses the CryptoNight (AscendingNight) hash algorithm, which is optimized for CPU-based mining and GPU resistance, with the Algo specializing in fair sharing of the hashrate.

Edit: AscendingNight is similar to CryptoNight (same scratchpad implode and explode) but it utilizes a different main algorithm. While CryptoNight uses one aes step every second step, AscendingNight uses one AES every fourth step, has some substitutional parts and things like that to perform less calculations for more memory intesety. In our private testing we came across performance boosts of 10% to 30% on Ryzen CPUs and up to 100% on older i7s. Since the memory utilisation is still the same, the algorithm is just as fast on GPU (mathematically speaking, not tested yet).

The thing cideg mentioned with Heavy, light and fast is just that, similar to CryptoNight, you can apply all the causal variations like CN-Heavy on AN as well (since it's just changing memory and iteration variables).

The point with the reference implementation of AscendingNight is that, while it's modular, it's still using 2MB as a scratchpad size and 2^14 iterations to increase the speeds of the validation process. By increasing the iteration number to the casual CryptoNight step count of 2^20 you'd see an even higher boost in the performance of CPUs compared to GPUs.

The important changes were done in the posr_aes macro. It can be found in here: https://github.com/Tax-Project/Tax/blob/master/src/crypto/slow-hash.c#L264

Links Algo= https://github.com/Tax-Project/Tax/blob/master/src/crypto/slow-hash.c http://clashproject.org/tax/ https://github.com/Tax-Project https://github.com/Tax-Project/Miner-UI

Feel free to checkout this Test-Pool:

http://207.180.246.163/#

Wallet: http://clashproject.org/tax/