From 2b9a588e25e86dcf5b30c11229084a7f7c6711f8 Mon Sep 17 00:00:00 2001 From: Zuikkis Date: Sun, 23 Feb 2014 18:20:57 +0200 Subject: [PATCH] Update sgminer.c & scrypt.c Default opt_nfactor was 11 instead of 10, my typo.. :) Sorry. scrypt_1024_1_1_256_sp renamed to scrypt_n_1_1_256_sp --- scrypt.c | 4 ++-- sgminer.c | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/scrypt.c b/scrypt.c index b2cc005d..acbd9828 100644 --- a/scrypt.c +++ b/scrypt.c @@ -356,7 +356,7 @@ salsa20_8(uint32_t B[16], const uint32_t Bx[16]) /* cpu and memory intensive function to transform a 80 byte buffer into a 32 byte output scratchpad size needs to be at least 63 + (128 * r * p) + (256 * r + 64) + (128 * r * N) bytes */ -static void scrypt_1024_1_1_256_sp(const uint32_t* input, char* scratchpad, uint32_t *ostate, const cl_uint n) +static void scrypt_n_1_1_256_sp(const uint32_t* input, char* scratchpad, uint32_t *ostate, const cl_uint n) { uint32_t * V; uint32_t X[32]; @@ -417,7 +417,7 @@ void scrypt_regenhash(struct work *work) data[19] = htobe32(*nonce); //scratchbuf = alloca(SCRATCHBUF_SIZE); scratchbuf = (char *)alloca((1 << opt_nfactor) * 128 + 512); - scrypt_1024_1_1_256_sp(data, scratchbuf, ohash, (1 << opt_nfactor)); + scrypt_n_1_1_256_sp(data, scratchbuf, ohash, (1 << opt_nfactor)); flip32(ohash, ohash); } diff --git a/sgminer.c b/sgminer.c index f16026e4..e3301337 100644 --- a/sgminer.c +++ b/sgminer.c @@ -92,7 +92,7 @@ int opt_log_interval = 5; int opt_queue = 1; int opt_scantime = 7; int opt_expiry = 28; -int opt_nfactor = 11; +int opt_nfactor = 10; static const bool opt_time = true; unsigned long long global_hashrate; unsigned long global_quota_gcd = 1;