Added benchmark and stress test

Easy to use and zero configuration embedded benchmark/stress test.
This commit is contained in:
SChernykh 2020-10-14 19:45:05 +02:00
parent 9fcc542676
commit 2ecece7b3d
28 changed files with 354 additions and 55 deletions

View file

@ -68,7 +68,7 @@ public:
{
m_rounds[index()]++;
if ((m_rounds[index()] % rounds) == 0) {
if ((m_rounds[index()] & (rounds - 1)) == 0) {
for (size_t i = 0; i < N; ++i) {
if (!Nonce::next(index(), nonce(i), rounds * roundSize, nonceMask())) {
return false;
@ -130,7 +130,7 @@ inline bool xmrig::WorkerJob<1>::nextRound(uint32_t rounds, uint32_t roundSize)
uint32_t* n = nonce();
if ((m_rounds[index()] % rounds) == 0) {
if ((m_rounds[index()] & (rounds - 1)) == 0) {
if (!Nonce::next(index(), n, rounds * roundSize, nonceMask())) {
return false;
}