Sanity checks (#88)

This commit is contained in:
tevador
2019-06-29 18:53:49 +02:00
committed by GitHub
parent c6b5ec12b6
commit aaa6e4e881
5 changed files with 54 additions and 10 deletions

View File

@@ -50,6 +50,10 @@ struct randomx_cache {
randomx::DatasetInitFunc* datasetInit;
randomx::SuperscalarProgram programs[RANDOMX_CACHE_ACCESSES];
std::vector<uint64_t> reciprocalCache;
bool isInitialized() {
return programs[0].getSize() != 0;
}
};
//A pointer to a standard-layout struct object points to its initial member