mirror of
https://github.com/GOSTSec/ccminer
synced 2025-01-10 23:08:02 +00:00
warnings: use the right device id (device_map[thr_id])
This commit is contained in:
parent
b1e9277611
commit
3d3f2e2cb5
@ -472,7 +472,7 @@ extern "C" int scanhash_blake256(int thr_id, uint32_t *pdata, const uint32_t *pt
|
||||
else if (opt_debug) {
|
||||
applog_hash((uchar*)ptarget);
|
||||
applog_compare_hash((uchar*)vhashcpu, (uchar*)ptarget);
|
||||
applog(LOG_DEBUG, "GPU #%d: result for nonce %08x does not validate on CPU!", thr_id, foundNonce);
|
||||
applog(LOG_WARNING, "GPU #%d: result for nonce %08x does not validate on CPU!", device_map[thr_id], foundNonce);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -79,7 +79,7 @@ extern "C" int scanhash_keccak256(int thr_id, uint32_t *pdata,
|
||||
return 1;
|
||||
}
|
||||
else {
|
||||
applog(LOG_DEBUG, "GPU #%d: result for nounce %08x does not validate on CPU!", thr_id, foundNonce);
|
||||
applog(LOG_WARNING, "GPU #%d: result for nounce %08x does not validate on CPU!", device_map[thr_id], foundNonce);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -228,9 +228,9 @@ extern "C" int scanhash_jackpot(int thr_id, uint32_t *pdata,
|
||||
}
|
||||
pdata[19] = foundNonce;
|
||||
return res;
|
||||
}
|
||||
else {
|
||||
applog(LOG_INFO, "GPU #%d: result for nonce $%08X does not validate on CPU (%d rounds)!", thr_id, foundNonce, rounds);
|
||||
} else {
|
||||
applog(LOG_WARNING, "GPU #%d: result for nonce %08x does not validate on CPU!",
|
||||
device_map[thr_id], foundNonce);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -132,7 +132,7 @@ extern "C" int scanhash_nist5(int thr_id, uint32_t *pdata,
|
||||
return res;
|
||||
}
|
||||
else {
|
||||
applog(LOG_INFO, "GPU #%d: result for nonce $%08X does not validate on CPU!", thr_id, foundNonce);
|
||||
applog(LOG_WARNING, "GPU #%d: result for nonce %08x does not validate on CPU!", device_map[thr_id], foundNonce);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -70,7 +70,8 @@ extern "C" int scanhash_fugue256(int thr_id, uint32_t *pdata, const uint32_t *pt
|
||||
*hashes_done = foundNounce - start_nonce + 1;
|
||||
return 1;
|
||||
} else {
|
||||
applog(LOG_INFO, "GPU #%d: result for nonce $%08X does not validate on CPU!", thr_id, foundNounce);
|
||||
applog(LOG_WARNING, "GPU #%d: result for nonce %08x does not validate on CPU!",
|
||||
device_map[thr_id], foundNounce);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -79,7 +79,7 @@ extern "C" int scanhash_groestlcoin(int thr_id, uint32_t *pdata, const uint32_t
|
||||
free(outputHash);
|
||||
return true;
|
||||
} else {
|
||||
applog(LOG_INFO, "GPU #%d: result for nonce $%08X does not validate on CPU!", thr_id, foundNounce);
|
||||
applog(LOG_WARNING, "GPU #%d: result for nonce %08x does not validate on CPU!", device_map[thr_id], foundNounce);
|
||||
}
|
||||
|
||||
foundNounce = 0xffffffff;
|
||||
|
@ -112,7 +112,7 @@ extern "C" int scanhash_lyra2(int thr_id, uint32_t *pdata,
|
||||
pdata[19] = foundNonce;
|
||||
return 1;
|
||||
} else {
|
||||
applog(LOG_INFO, "GPU #%d: result for %08x does not validate on CPU!", thr_id, foundNonce);
|
||||
applog(LOG_WARNING, "GPU #%d: result for %08x does not validate on CPU!", device_map[thr_id], foundNonce);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -82,7 +82,7 @@ extern "C" int scanhash_myriad(int thr_id, uint32_t *pdata, const uint32_t *ptar
|
||||
free(outputHash);
|
||||
return true;
|
||||
} else {
|
||||
applog(LOG_INFO, "GPU #%d: result for nonce $%08X does not validate on CPU!", thr_id, foundNounce);
|
||||
applog(LOG_WARNING, "GPU #%d: result for nonce %08x does not validate on CPU!", device_map[thr_id], foundNounce);
|
||||
}
|
||||
|
||||
foundNounce = 0xffffffff;
|
||||
|
@ -424,12 +424,8 @@ extern "C" int scanhash_pentablake(int thr_id, uint32_t *pdata, const uint32_t *
|
||||
}
|
||||
pdata[19] = foundNonce;
|
||||
return rc;
|
||||
}
|
||||
else if (vhashcpu[7] > Htarg) {
|
||||
applog(LOG_WARNING, "GPU #%d: result for nounce %08x is not in range: %x > %x", thr_id, foundNonce, vhashcpu[7], Htarg);
|
||||
}
|
||||
else {
|
||||
applog(LOG_WARNING, "GPU #%d: result for nounce %08x does not validate on CPU!", thr_id, foundNonce);
|
||||
} else {
|
||||
applog(LOG_WARNING, "GPU #%d: result for nounce %08x does not validate on CPU!", device_map[thr_id], foundNonce);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -194,7 +194,6 @@ extern "C" int scanhash_pluck(int thr_id, uint32_t *pdata, const uint32_t *ptarg
|
||||
if (!init[thr_id])
|
||||
{
|
||||
cudaSetDevice(device_map[thr_id]);
|
||||
//cudaDeviceReset();
|
||||
//cudaSetDeviceFlags(cudaDeviceScheduleBlockingSync);
|
||||
//cudaDeviceSetCacheConfig(cudaFuncCachePreferL1);
|
||||
cudaMalloc(&d_hash[thr_id], opt_pluck_n * 1024 * throughput);
|
||||
@ -224,7 +223,7 @@ extern "C" int scanhash_pluck(int thr_id, uint32_t *pdata, const uint32_t *ptarg
|
||||
pdata[19] = foundNonce;
|
||||
return 1;
|
||||
} else {
|
||||
applog(LOG_INFO, "GPU #%d: result for %08x does not validate on CPU!", thr_id, foundNonce);
|
||||
applog(LOG_WARNING, "GPU #%d: result for %08x does not validate on CPU!", device_map[thr_id], foundNonce);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -274,7 +274,7 @@ extern "C" int scanhash_anime(int thr_id, uint32_t *pdata,
|
||||
pdata[19] = foundNonce;
|
||||
return res;
|
||||
} else {
|
||||
applog(LOG_INFO, "GPU #%d: result for nonce $%08X does not validate on CPU!", thr_id, foundNonce);
|
||||
applog(LOG_WARNING, "GPU #%d: result for nonce %08x does not validate on CPU!", device_map[thr_id], foundNonce);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -241,7 +241,7 @@ extern "C" int scanhash_quark(int thr_id, uint32_t *pdata,
|
||||
*hashes_done = foundNonce - first_nonce + 1;
|
||||
return 1;
|
||||
} else {
|
||||
applog(LOG_INFO, "GPU #%d: result for nonce $%08X does not validate on CPU!", thr_id, foundNonce);
|
||||
applog(LOG_WARNING, "GPU #%d: result for nonce %08x does not validate on CPU!", device_map[thr_id], foundNonce);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -113,7 +113,7 @@ extern "C" int scanhash_deep(int thr_id, uint32_t *pdata,
|
||||
return res;
|
||||
}
|
||||
else {
|
||||
applog(LOG_INFO, "GPU #%d: result for nonce $%08X does not validate on CPU!", thr_id, foundNonce);
|
||||
applog(LOG_WARNING, "GPU #%d: result for nonce %08x does not validate on CPU!", device_map[thr_id], foundNonce);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -77,9 +77,8 @@ extern "C" int scanhash_doom(int thr_id, uint32_t *pdata,
|
||||
*hashes_done = min(max_nonce - first_nonce, (uint64_t) pdata[19] - first_nonce + throughput);
|
||||
pdata[19] = foundNonce;
|
||||
return 1;
|
||||
}
|
||||
else {
|
||||
applog(LOG_INFO, "GPU #%d: result for nonce $%08X does not validate on CPU!", thr_id, foundNonce);
|
||||
} else {
|
||||
applog(LOG_WARNING, "GPU #%d: result for nonce %08x does not validate on CPU!", device_map[thr_id], foundNonce);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -139,7 +139,7 @@ extern "C" int scanhash_qubit(int thr_id, uint32_t *pdata,
|
||||
return res;
|
||||
}
|
||||
else {
|
||||
applog(LOG_INFO, "GPU #%d: result for nonce $%08X does not validate on CPU!", thr_id, foundNonce);
|
||||
applog(LOG_WARNING, "GPU #%d: result for nonce %08x does not validate on CPU!", device_map[thr_id], foundNonce);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -595,8 +595,6 @@ int scanhash_scrypt_jane(int thr_id, uint32_t *pdata, const uint32_t *ptarget, u
|
||||
|
||||
if (memcmp(thash, &hash[cur][8*i], 32) == 0)
|
||||
{
|
||||
//applog(LOG_INFO, "GPU #%d: %s result validates on CPU.", device_map[thr_id], device_name[thr_id]);
|
||||
|
||||
*hashes_done = n - pdata[19];
|
||||
pdata[19] = tmp_nonce;
|
||||
scrypt_free(&Vbuf);
|
||||
@ -606,7 +604,8 @@ int scanhash_scrypt_jane(int thr_id, uint32_t *pdata, const uint32_t *ptarget, u
|
||||
gettimeofday(tv_end, NULL);
|
||||
return 1;
|
||||
} else {
|
||||
applog(LOG_INFO, "GPU #%d: %s result does not validate on CPU (i=%d, s=%d)!", device_map[thr_id], device_name[thr_id], i, cur);
|
||||
applog(LOG_WARNING, "GPU #%d: %s result does not validate on CPU! (i=%d, s=%d)",
|
||||
device_map[thr_id], device_name[thr_id], i, cur);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -896,9 +896,10 @@ int scanhash_scrypt(int thr_id, uint32_t *pdata, const uint32_t *ptarget, unsign
|
||||
if (memcmp(&hash[cur][i * 8], refhash, 32) != 0) good = false;
|
||||
}
|
||||
|
||||
if (!good)
|
||||
applog(LOG_INFO, "GPU #%d: %s result does not validate on CPU (i=%d, s=%d)!", device_map[thr_id], device_name[thr_id], i, cur);
|
||||
else {
|
||||
if (!good) {
|
||||
applog(LOG_WARNING, "GPU #%d: %s result does not validate on CPU! (i=%d, s=%d)",
|
||||
device_map[thr_id], device_name[thr_id], i, cur);
|
||||
} else {
|
||||
*hashes_done = n - pdata[19];
|
||||
pdata[19] = nonce[cur] + i;
|
||||
result = 1;
|
||||
|
2
skein.cu
2
skein.cu
@ -413,7 +413,7 @@ extern "C" int scanhash_skeincoin(int thr_id, uint32_t *pdata, const uint32_t *p
|
||||
return res;
|
||||
}
|
||||
else {
|
||||
applog(LOG_INFO, "GPU #%d: result for nonce $%08X does not validate on CPU!", device_map[thr_id], foundNonce);
|
||||
applog(LOG_WARNING, "GPU #%d: result for nonce %08x does not validate on CPU!", device_map[thr_id], foundNonce);
|
||||
}
|
||||
}
|
||||
pdata[19] += throughput;
|
||||
|
@ -95,9 +95,8 @@ extern "C" int scanhash_skein2(int thr_id, uint32_t *pdata, const uint32_t *ptar
|
||||
}
|
||||
pdata[19] = swab32(foundNonce);
|
||||
return res;
|
||||
}
|
||||
else {
|
||||
applog(LOG_INFO, "GPU #%d: result for nonce $%08X does not validate on CPU!", device_map[thr_id], foundNonce);
|
||||
} else {
|
||||
applog(LOG_WARNING, "GPU #%d: result for nonce %08x does not validate on CPU!", device_map[thr_id], foundNonce);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -140,12 +140,8 @@ extern "C" int scanhash_fresh(int thr_id, uint32_t *pdata,
|
||||
}
|
||||
pdata[19] = foundNonce;
|
||||
return res;
|
||||
}
|
||||
else if (vhash64[7] > Htarg) {
|
||||
applog(LOG_INFO, "GPU #%d: result for %08x is not in range: %x > %x", thr_id, foundNonce, vhash64[7], Htarg);
|
||||
}
|
||||
else {
|
||||
applog(LOG_INFO, "GPU #%d: result for %08x does not validate on CPU!", thr_id, foundNonce);
|
||||
} else {
|
||||
applog(LOG_WARNING, "GPU #%d: result for %08x does not validate on CPU!", device_map[thr_id], foundNonce);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -119,7 +119,7 @@ extern "C" int scanhash_s3(int thr_id, uint32_t *pdata,
|
||||
return res;
|
||||
|
||||
} else {
|
||||
applog(LOG_INFO, "GPU #%d: result for nonce $%08X does not validate on CPU!", thr_id, foundNonce);
|
||||
applog(LOG_WARNING, "GPU #%d: result for nonce $%08X does not validate on CPU!", device_map[thr_id], foundNonce);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -230,12 +230,8 @@ extern "C" int scanhash_x11(int thr_id, uint32_t *pdata,
|
||||
}
|
||||
pdata[19] = foundNonce;
|
||||
return res;
|
||||
}
|
||||
else if (vhash64[7] > Htarg) {
|
||||
applog(LOG_INFO, "GPU #%d: result for %08x is not in range: %x > %x", thr_id, foundNonce, vhash64[7], Htarg);
|
||||
}
|
||||
else {
|
||||
applog(LOG_INFO, "GPU #%d: result for %08x does not validate on CPU!", thr_id, foundNonce);
|
||||
} else {
|
||||
applog(LOG_WARNING, "GPU #%d: result for %08x does not validate on CPU!", device_map[thr_id], foundNonce);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -226,12 +226,8 @@ extern "C" int scanhash_x13(int thr_id, uint32_t *pdata,
|
||||
}
|
||||
pdata[19] = foundNonce;
|
||||
return res;
|
||||
}
|
||||
else if (vhash64[7] > Htarg) {
|
||||
applog(LOG_INFO, "GPU #%d: result for %08x is not in range: %x > %x", thr_id, foundNonce, vhash64[7], Htarg);
|
||||
}
|
||||
else {
|
||||
applog(LOG_INFO, "GPU #%d: result for %08x does not validate on CPU!", thr_id, foundNonce);
|
||||
} else {
|
||||
applog(LOG_WARNING, "GPU #%d: result for %08x does not validate on CPU!", device_map[thr_id], foundNonce);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -106,12 +106,8 @@ extern "C" int scanhash_whc(int thr_id, uint32_t *pdata,
|
||||
#endif
|
||||
pdata[19] = foundNonce;
|
||||
return res;
|
||||
}
|
||||
else if (vhash64[7] > Htarg) {
|
||||
applog(LOG_INFO, "GPU #%d: result for %08x is not in range: %x > %x", thr_id, foundNonce, vhash64[7], Htarg);
|
||||
}
|
||||
else {
|
||||
applog(LOG_INFO, "GPU #%d: result for %08x does not validate on CPU!", thr_id, foundNonce);
|
||||
} else {
|
||||
applog(LOG_WARNING, "GPU #%d: result for %08x does not validate on CPU!", device_map[thr_id], foundNonce);
|
||||
}
|
||||
}
|
||||
pdata[19] += throughput;
|
||||
|
@ -78,12 +78,8 @@ extern "C" int scanhash_whirlpoolx(int thr_id, uint32_t *pdata, const uint32_t *
|
||||
*hashes_done = pdata[19] - first_nonce + throughput;
|
||||
pdata[19] = foundNonce;
|
||||
return 1;
|
||||
}
|
||||
else if (vhash64[7] > Htarg) {
|
||||
applog(LOG_INFO, "GPU #%d: result for %08x is not in range: %x > %x", thr_id, foundNonce, vhash64[7], Htarg);
|
||||
}
|
||||
else {
|
||||
applog(LOG_INFO, "GPU #%d: result for %08x does not validate on CPU!", thr_id, foundNonce);
|
||||
} else {
|
||||
applog(LOG_WARNING, "GPU #%d: result for %08x does not validate on CPU!", device_map[thr_id], foundNonce);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -235,12 +235,8 @@ extern "C" int scanhash_x14(int thr_id, uint32_t *pdata,
|
||||
}
|
||||
pdata[19] = foundNonce;
|
||||
return res;
|
||||
}
|
||||
else if (vhash64[7] > Htarg) {
|
||||
applog(LOG_INFO, "GPU #%d: result for %08x is not in range: %x > %x", thr_id, foundNonce, vhash64[7], Htarg);
|
||||
}
|
||||
else {
|
||||
applog(LOG_INFO, "GPU #%d: result for %08x does not validate on CPU!", thr_id, foundNonce);
|
||||
} else {
|
||||
applog(LOG_WARNING, "GPU #%d: result for %08x does not validate on CPU!", device_map[thr_id], foundNonce);
|
||||
}
|
||||
}
|
||||
pdata[19] += throughput;
|
||||
|
@ -247,12 +247,8 @@ extern "C" int scanhash_x15(int thr_id, uint32_t *pdata,
|
||||
}
|
||||
pdata[19] = foundNonce;
|
||||
return res;
|
||||
}
|
||||
else if (vhash64[7] > Htarg) {
|
||||
applog(LOG_INFO, "GPU #%d: result for %08x is not in range: %x > %x", thr_id, foundNonce, vhash64[7], Htarg);
|
||||
}
|
||||
else {
|
||||
applog(LOG_INFO, "GPU #%d: result for %08x does not validate on CPU!", thr_id, foundNonce);
|
||||
} else {
|
||||
applog(LOG_WARNING, "GPU #%d: result for %08x does not validate on CPU!", device_map[thr_id], foundNonce);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -272,12 +272,8 @@ extern "C" int scanhash_x17(int thr_id, uint32_t *pdata,
|
||||
}
|
||||
pdata[19] = foundNonce;
|
||||
return res;
|
||||
}
|
||||
else if (vhash64[7] > Htarg) {
|
||||
applog(LOG_INFO, "GPU #%d: result for %08x is not in range: %x > %x", thr_id, foundNonce, vhash64[7], Htarg);
|
||||
}
|
||||
else {
|
||||
applog(LOG_INFO, "GPU #%d: result for %08x does not validate on CPU!", thr_id, foundNonce);
|
||||
} else {
|
||||
applog(LOG_WARNING, "GPU #%d: result for %08x does not validate on CPU!", device_map[thr_id], foundNonce);
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user