Cleanup hugepages status
This commit is contained in:
parent
c7f133a6e3
commit
9ff4ec3288
5 changed files with 4 additions and 23 deletions
|
@ -1,7 +1,7 @@
|
|||
# 1.6.5
|
||||
- Hashrate improve -> add autodetection mode for cpu-affinity
|
||||
- Hashrate improve, more stable hashrates -> refactor memory allocation
|
||||
- Add Arto (RTO) support (cn [2mb scratchpag] + ipbc mod)
|
||||
- Add Arto (RTO) support (cn [2mb scratchpad] + ipbc mod)
|
||||
- Add TubeV4 (TUBE) support (cn-heavy [4mb scratchpad] + ipbc mod + soft-aes mod)
|
||||
- Add external IP to log view
|
||||
- Fix memory leak in RemoteLog
|
||||
|
|
|
@ -567,8 +567,7 @@
|
|||
tooltip += '\n';
|
||||
tooltip += "CPU Cache L2/L3: " + (row.client_status.cpu_l2 / 1024) + " MB/"+ (row.client_status.cpu_l3 / 1024) + " MB";
|
||||
tooltip += '\n';
|
||||
tooltip += "Huge Pages: " + (row.client_status.hugepages_available ? " available, " : " unavailable, ");
|
||||
tooltip += (row.client_status.hugepages_enabled ? "enabled" : "disabled");
|
||||
tooltip += "Huge Pages: " + (row.client_status.hugepages_available ? " available" : " unavailable");
|
||||
tooltip += '\n';
|
||||
tooltip += "Used Threads: " + row.client_status.current_threads;
|
||||
tooltip += (row.client_status.hash_factor > 1 ? " [" + row.client_status.hash_factor + "x multi hash mode]" :"");
|
||||
|
|
|
@ -59,6 +59,8 @@ void Mem::allocate(ScratchPadMem& scratchPadMem, bool useHugePages)
|
|||
return allocate(scratchPadMem, false);
|
||||
}
|
||||
|
||||
m_flags |= HugepagesAvailable;
|
||||
|
||||
scratchPadMem.hugePages = scratchPadMem.pages;
|
||||
|
||||
if (madvise(scratchPadMem.memory, scratchPadMem.size, MADV_RANDOM | MADV_WILLNEED) != 0) {
|
||||
|
|
|
@ -34,7 +34,6 @@
|
|||
ClientStatus::ClientStatus()
|
||||
: m_currentStatus(Status::PAUSED),
|
||||
m_hasHugepages(false),
|
||||
m_isHugepagesEnabled(false),
|
||||
m_isCpuX64(false),
|
||||
m_hasCpuAES(false),
|
||||
m_hashFactor(1),
|
||||
|
@ -158,16 +157,6 @@ void ClientStatus::setHugepages(bool hasHugepages)
|
|||
m_hasHugepages = hasHugepages;
|
||||
}
|
||||
|
||||
bool ClientStatus::isHugepagesEnabled() const
|
||||
{
|
||||
return m_isHugepagesEnabled;
|
||||
}
|
||||
|
||||
void ClientStatus::setHugepagesEnabled(bool hugepagesEnabled)
|
||||
{
|
||||
m_isHugepagesEnabled = hugepagesEnabled;
|
||||
}
|
||||
|
||||
int ClientStatus::getHashFactor() const
|
||||
{
|
||||
return m_hashFactor;
|
||||
|
@ -400,10 +389,6 @@ bool ClientStatus::parseFromJson(const rapidjson::Document& document)
|
|||
m_hasHugepages = clientStatus["hugepages_available"].GetBool();
|
||||
}
|
||||
|
||||
if (clientStatus.HasMember("hugepages_enabled")) {
|
||||
m_isHugepagesEnabled = clientStatus["hugepages_enabled"].GetBool();
|
||||
}
|
||||
|
||||
if (clientStatus.HasMember("hash_factor")) {
|
||||
m_hashFactor = clientStatus["hash_factor"].GetInt();
|
||||
}
|
||||
|
@ -502,7 +487,6 @@ rapidjson::Value ClientStatus::toJson(rapidjson::MemoryPoolAllocator<rapidjson::
|
|||
clientStatus.AddMember("version", rapidjson::StringRef(m_version.c_str()), allocator);
|
||||
|
||||
clientStatus.AddMember("hugepages_available", m_hasHugepages, allocator);
|
||||
clientStatus.AddMember("hugepages_enabled", m_isHugepagesEnabled, allocator);
|
||||
clientStatus.AddMember("hash_factor", m_hashFactor, allocator);
|
||||
clientStatus.AddMember("cpu_is_x64", m_isCpuX64, allocator);
|
||||
clientStatus.AddMember("cpu_has_aes", m_hasCpuAES, allocator);
|
||||
|
|
|
@ -87,9 +87,6 @@ public:
|
|||
bool hasHugepages() const;
|
||||
void setHugepages(bool hasHugepages);
|
||||
|
||||
bool isHugepagesEnabled() const;
|
||||
void setHugepagesEnabled(bool hugepagesEnabled);
|
||||
|
||||
int getHashFactor() const;
|
||||
void setHashFactor(int hashFactor);
|
||||
|
||||
|
@ -170,7 +167,6 @@ private:
|
|||
std::string m_log;
|
||||
|
||||
bool m_hasHugepages;
|
||||
bool m_isHugepagesEnabled;
|
||||
bool m_isCpuX64;
|
||||
bool m_hasCpuAES;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue