Added config option "cpu/max-threads-hint" and command line option "--cpu-max-threads-hint".

This commit is contained in:
XMRig 2019-09-28 02:02:20 +07:00
parent daed23422e
commit 7c463849cc
14 changed files with 97 additions and 57 deletions

View file

@ -44,6 +44,7 @@ class Threads
public:
inline bool has(const char *profile) const { return m_profiles.count(profile) > 0; }
inline bool isDisabled(const Algorithm &algo) const { return m_disabled.count(algo) > 0; }
inline bool isEmpty() const { return m_profiles.empty(); }
inline bool isExist(const Algorithm &algo) const { return isDisabled(algo) || m_aliases.count(algo) > 0 || has(algo.shortName()); }
inline const T &get(const Algorithm &algo, bool strict = false) const { return get(profileName(algo, strict)); }
inline void disable(const Algorithm &algo) { m_disabled.insert(algo); }