RandomWOW support

This commit is contained in:
SChernykh 2019-06-15 22:53:03 +02:00
parent 277f188cd5
commit ac1b554282
14 changed files with 157 additions and 3 deletions

View file

@ -34,6 +34,7 @@
#include "base/net/stratum/Job.h"
#include "net/JobResult.h"
#include "rapidjson/fwd.h"
#include "randomwow.h"
class Hashrate;
@ -72,6 +73,9 @@ public:
static void threadsSummary(rapidjson::Document &doc);
# endif
static void updateDataset(const uint8_t* seed_hash, uint32_t num_threads);
static randomx_dataset* getDataset();
private:
static void onReady(void *arg);
static void onResult(uv_async_t *handle);
@ -114,6 +118,12 @@ private:
static uv_rwlock_t m_rwlock;
static uv_timer_t *m_timer;
static xmrig::Controller *m_controller;
static uv_rwlock_t m_rx_dataset_lock;
static randomx_cache *m_rx_cache;
static randomx_dataset *m_rx_dataset;
static uint8_t m_rx_seed_hash[32];
static std::atomic<uint32_t> m_rx_dataset_init_thread_counter;
};