1
0
mirror of https://github.com/xmrig/xmrig.git synced 2025-12-07 07:55:04 -05:00

Compare commits

...

7 Commits

Author SHA1 Message Date
Artem Zuikov
fe145c4166 Merge ead82cdba9 into e8bbd134f9 2024-11-03 19:13:59 +02:00
XMRig
e8bbd134f9 v6.22.3-dev 2024-11-03 15:06:54 +07:00
XMRig
cf86a1e05c Merge branch 'master' into dev 2024-11-03 15:06:22 +07:00
XMRig
f9e990d0f0 v6.22.2 2024-11-03 14:38:44 +07:00
XMRig
200f23bba7 Merge branch 'dev' 2024-11-03 14:38:00 +07:00
xmrig
4234b20e21 Update CHANGELOG.md 2024-11-03 14:31:17 +07:00
4ertus2
ead82cdba9 prevent manual mutex lock/unlock 2024-10-20 23:21:00 +03:00
6 changed files with 38 additions and 28 deletions

View File

@@ -1,3 +1,7 @@
# v6.22.2
- [#3569](https://github.com/xmrig/xmrig/pull/3569) Fixed corrupted API output in some rare conditions.
- [#3571](https://github.com/xmrig/xmrig/pull/3571) Fixed number of threads on the new Intel Core Ultra CPUs.
# v6.22.1
- [#3531](https://github.com/xmrig/xmrig/pull/3531) Always reset nonce on RandomX dataset change.
- [#3534](https://github.com/xmrig/xmrig/pull/3534) Fixed threads auto-config on Zen5.

View File

@@ -180,11 +180,11 @@ public:
}
# endif
mutex.lock();
{
std::lock_guard<std::mutex> lock(mutex);
pages += status.hugePages();
mutex.unlock();
pages += status.hugePages();
}
rapidjson::Value hugepages;
@@ -380,14 +380,14 @@ void xmrig::CpuBackend::setJob(const Job &job)
void xmrig::CpuBackend::start(IWorker *worker, bool ready)
{
mutex.lock();
{
std::lock_guard<std::mutex> lock(mutex);
if (d_ptr->status.started(worker, ready)) {
d_ptr->status.print();
if (d_ptr->status.started(worker, ready)) {
d_ptr->status.print();
}
}
mutex.unlock();
if (ready) {
worker->start();
}

View File

@@ -465,16 +465,17 @@ void xmrig::CudaBackend::setJob(const Job &job)
void xmrig::CudaBackend::start(IWorker *worker, bool ready)
{
mutex.lock();
{
std::lock_guard<std::mutex> lock(mutex);
if (d_ptr->status.started(ready)) {
d_ptr->status.print();
if (d_ptr->status.started(ready)) {
d_ptr->status.print();
CudaWorker::ready = true;
}
CudaWorker::ready = true;
}
mutex.unlock();
if (ready) {
worker->start();
}

View File

@@ -447,16 +447,16 @@ void xmrig::OclBackend::setJob(const Job &job)
void xmrig::OclBackend::start(IWorker *worker, bool ready)
{
mutex.lock();
{
std::lock_guard<std::mutex> lock(mutex);
if (d_ptr->status.started(ready)) {
d_ptr->status.print();
if (d_ptr->status.started(ready)) {
d_ptr->status.print();
OclWorker::ready = true;
OclWorker::ready = true;
}
}
mutex.unlock();
if (ready) {
worker->start();
}

View File

@@ -569,7 +569,14 @@ void xmrig::Miner::setJob(const Job &job, bool donate)
d_ptr->algorithm = job.algorithm();
mutex.lock();
# ifdef XMRIG_ALGO_RANDOMX
bool ready = false;
# else
constexpr const bool ready = true;
# endif
{
std::lock_guard<std::mutex> lock(mutex);
const uint8_t index = donate ? 1 : 0;
@@ -588,14 +595,12 @@ void xmrig::Miner::setJob(const Job &job, bool donate)
}
# ifdef XMRIG_ALGO_RANDOMX
const bool ready = d_ptr->initRX();
ready = d_ptr->initRX();
// Always reset nonce on RandomX dataset change
if (!ready) {
d_ptr->reset = true;
}
# else
constexpr const bool ready = true;
# endif
# ifdef XMRIG_ALGO_GHOSTRIDER
@@ -604,7 +609,7 @@ void xmrig::Miner::setJob(const Job &job, bool donate)
}
# endif
mutex.unlock();
}
d_ptr->active = true;
d_ptr->m_taskbar.setActive(true);

View File

@@ -22,7 +22,7 @@
#define APP_ID "xmrig"
#define APP_NAME "XMRig"
#define APP_DESC "XMRig miner"
#define APP_VERSION "6.22.2-dev"
#define APP_VERSION "6.22.3-dev"
#define APP_DOMAIN "xmrig.com"
#define APP_SITE "www.xmrig.com"
#define APP_COPYRIGHT "Copyright (C) 2016-2024 xmrig.com"
@@ -30,7 +30,7 @@
#define APP_VER_MAJOR 6
#define APP_VER_MINOR 22
#define APP_VER_PATCH 2
#define APP_VER_PATCH 3
#ifdef _MSC_VER
# if (_MSC_VER >= 1930)