Add Masari v7 support (#133)
This commit is contained in:
parent
e23743980e
commit
ae15b9f5ac
7 changed files with 22 additions and 9 deletions
|
@ -281,7 +281,8 @@ constexpr static const char *pow_variant_names[] = {
|
|||
"1",
|
||||
"ipbc",
|
||||
"alloy",
|
||||
"xtl"
|
||||
"xtl",
|
||||
"msr"
|
||||
};
|
||||
|
||||
Options *Options::parse(int argc, char **argv)
|
||||
|
@ -1022,7 +1023,6 @@ bool Options::parsePowVariant(const char *powVariant)
|
|||
break;
|
||||
}
|
||||
|
||||
|
||||
if (i == ARRAY_SIZE(pow_variant_names) - 1 && !strcmp(powVariant, "tube")) {
|
||||
m_powVariant = POW_IPBC;
|
||||
break;
|
||||
|
|
|
@ -30,6 +30,7 @@ enum PowVariant
|
|||
POW_IPBC,
|
||||
POW_ALLOY,
|
||||
POW_XTL,
|
||||
POW_MSR,
|
||||
LAST_ITEM
|
||||
};
|
||||
|
||||
|
@ -47,6 +48,8 @@ inline std::string getPowVariantName(PowVariant powVariant)
|
|||
return "alloy";
|
||||
case POW_XTL:
|
||||
return "xtl";
|
||||
case POW_MSR:
|
||||
return "msr";
|
||||
case POW_AUTODETECT:
|
||||
default:
|
||||
return "-1";
|
||||
|
@ -95,12 +98,14 @@ inline PowVariant parseVariant(const std::string variant)
|
|||
powVariant = PowVariant::POW_V0;
|
||||
} else if (variant == "1") {
|
||||
powVariant = PowVariant::POW_V1;
|
||||
} else if (variant == "ipbc") {
|
||||
} else if (variant == "ipbc" || variant == "tube") {
|
||||
powVariant = PowVariant::POW_IPBC;
|
||||
} else if (variant == "alloy") {
|
||||
} else if (variant == "xao" || variant == "alloy") {
|
||||
powVariant = PowVariant::POW_ALLOY;
|
||||
} else if (variant == "xtl") {
|
||||
} else if (variant == "xtl" || variant == "stellite") {
|
||||
powVariant = PowVariant::POW_XTL;
|
||||
} else if (variant == "msr" || variant == "masari") {
|
||||
powVariant = PowVariant::POW_MSR;
|
||||
}
|
||||
|
||||
return powVariant;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{
|
||||
"algo": "cryptonight", // cryptonight (default), cryptonight-lite or cryptopnight-heavy
|
||||
"algo": "cryptonight", // cryptonight (default), cryptonight-lite or cryptonight-heavy
|
||||
"aesni": 0, // selection of AES-NI mode (0 auto, 1 on, 2 off)
|
||||
"threads": 0, // number of miner threads (not set or 0 enables automatic selection of optimal thread count)
|
||||
"multihash-factor": 0, // number of hash blocks to process at a time (not set or 0 enables automatic selection of optimal number of hash blocks)
|
||||
|
@ -33,7 +33,7 @@
|
|||
"use-tls" : false, // enable tls for CC communication (needs to be enabled on CC Server too)
|
||||
"access-token": "mySecret", // access token for CC Server (has to be the same in config_cc.json)
|
||||
"worker-id": null, // custom worker-id for CC Server (otherwise hostname is used)
|
||||
"update-interval-s": 10 // status update interval in seconds (default: 10 min: 1)
|
||||
"update-interval-s": 10, // status update interval in seconds (default: 10 min: 1)
|
||||
"use-remote-logging" : true, // enable remote logging on CC Server
|
||||
"remote-logging-max-rows" : 20 // maximum last n-log rows to send CC Server
|
||||
}
|
||||
|
|
|
@ -42,6 +42,8 @@ static void cryptonight_aesni(PowVariant powVersion, const uint8_t* input, size_
|
|||
CryptoNightMultiHash<0x100000, POW_DEFAULT_INDEX_SHIFT, MEMORY, 0x1FFFF0, false, NUM_HASH_BLOCKS>::hash(input, size, output, ctx);
|
||||
} else if (powVersion == PowVariant::POW_XTL) {
|
||||
CryptoNightMultiHash<0x80000, POW_XLT_V4_INDEX_SHIFT, MEMORY, 0x1FFFF0, false, NUM_HASH_BLOCKS>::hashPowV2(input, size, output, ctx);
|
||||
} else if (powVersion == PowVariant::POW_MSR) {
|
||||
CryptoNightMultiHash<0x40000, POW_DEFAULT_INDEX_SHIFT, MEMORY, 0x1FFFF0, false, NUM_HASH_BLOCKS>::hashPowV2(input, size, output, ctx);
|
||||
} else {
|
||||
CryptoNightMultiHash<0x80000, POW_DEFAULT_INDEX_SHIFT, MEMORY, 0x1FFFF0, false, NUM_HASH_BLOCKS>::hash(input, size, output, ctx);
|
||||
}
|
||||
|
@ -56,6 +58,8 @@ static void cryptonight_softaes(PowVariant powVersion, const uint8_t* input, siz
|
|||
CryptoNightMultiHash<0x100000, POW_DEFAULT_INDEX_SHIFT, MEMORY, 0x1FFFF0, true, NUM_HASH_BLOCKS>::hash(input, size, output, ctx);
|
||||
} else if (powVersion == PowVariant::POW_XTL) {
|
||||
CryptoNightMultiHash<0x80000, POW_XLT_V4_INDEX_SHIFT, MEMORY, 0x1FFFF0, true, NUM_HASH_BLOCKS>::hashPowV2(input, size, output, ctx);
|
||||
} else if (powVersion == PowVariant::POW_MSR) {
|
||||
CryptoNightMultiHash<0x40000, POW_DEFAULT_INDEX_SHIFT, MEMORY, 0x1FFFF0, true, NUM_HASH_BLOCKS>::hashPowV2(input, size, output, ctx);
|
||||
} else {
|
||||
CryptoNightMultiHash<0x80000, POW_DEFAULT_INDEX_SHIFT, MEMORY, 0x1FFFF0, true, NUM_HASH_BLOCKS>::hash(input, size, output, ctx);
|
||||
}
|
||||
|
|
|
@ -33,7 +33,7 @@
|
|||
"use-tls" : false, // enable tls for CC communication (needs to be enabled on CC Server too)
|
||||
"access-token": "mySecret", // access token for CC Server (has to be the same in config_cc.json)
|
||||
"worker-id": null, // custom worker-id for CC Server (otherwise hostname is used)
|
||||
"update-interval-s": 10 // status update interval in seconds (default: 10 min: 1)
|
||||
"update-interval-s": 10, // status update interval in seconds (default: 10 min: 1)
|
||||
"use-remote-logging" : true, // enable remote logging on CC Server
|
||||
"remote-logging-max-rows" : 20 // maximum last n-log rows to send CC Server
|
||||
}
|
||||
|
|
|
@ -146,6 +146,10 @@ PowVariant Job::powVariant() const
|
|||
{
|
||||
return POW_V1;
|
||||
}
|
||||
else if (m_powVariant == PowVariant::POW_MSR && m_blob[0] < 7)
|
||||
{
|
||||
return POW_V1;
|
||||
}
|
||||
else
|
||||
{
|
||||
return m_powVariant;
|
||||
|
|
|
@ -36,7 +36,7 @@
|
|||
#define APP_DESC "XMRigCC CPU miner"
|
||||
#define APP_COPYRIGHT "Copyright (C) 2017- BenDr0id"
|
||||
#endif
|
||||
#define APP_VERSION "1.6.4_beta1 (based on XMRig)"
|
||||
#define APP_VERSION "1.6.4_masari_v7_support (based on XMRig)"
|
||||
#define APP_DOMAIN ""
|
||||
#define APP_SITE "https://github.com/Bendr0id/xmrigCC"
|
||||
#define APP_KIND "cpu"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue