Merging debug_profile_verify & debug_blake2b_generate
This commit is contained in:
parent
954bdc49fa
commit
16f61eca51
1 changed files with 6 additions and 19 deletions
|
@ -123,7 +123,6 @@ int main (int argc, char * const * argv)
|
|||
("debug_profile_kdf", "Profile kdf function")
|
||||
("debug_verify_profile", "Profile signature verification")
|
||||
("debug_xorshift_profile", "Profile xorshift algorithms")
|
||||
("debug_blake2b_generate", "Blake2b work generation")
|
||||
("platform", boost::program_options::value <std::string> (), "Defines the <platform> for OpenCL commands")
|
||||
("device", boost::program_options::value <std::string> (), "Defines <device> for OpenCL command")
|
||||
("threads", boost::program_options::value <std::string> (), "Defines <threads> count for OpenCL command");
|
||||
|
@ -269,23 +268,6 @@ int main (int argc, char * const * argv)
|
|||
std::cerr << boost::str (boost::format ("%|1$ 12d|\n") % std::chrono::duration_cast <std::chrono::microseconds> (end1 - begin1).count ());
|
||||
}
|
||||
}
|
||||
else if (vm.count ("debug_blake2b_generate"))
|
||||
{
|
||||
rai::work_pool work (std::numeric_limits <unsigned>::max (), nullptr);
|
||||
rai::change_block block (0, 0, rai::keypair ().prv, 0, 0);
|
||||
for (uint64_t i (0); true; ++i)
|
||||
{
|
||||
block.hashables.previous.qwords [0] += 1;
|
||||
auto begin1 (std::chrono::high_resolution_clock::now ());
|
||||
auto hash (block.hash ());
|
||||
for (uint64_t t (0); t < 1000000; ++t)
|
||||
{
|
||||
work.work_value (hash, t);
|
||||
}
|
||||
auto end1 (std::chrono::high_resolution_clock::now ());
|
||||
std::cerr << boost::str (boost::format ("%|1$ 12d|\n") % std::chrono::duration_cast <std::chrono::microseconds> (end1 - begin1).count ());
|
||||
}
|
||||
}
|
||||
else if (vm.count ("debug_opencl"))
|
||||
{
|
||||
bool error (false);
|
||||
|
@ -376,7 +358,12 @@ int main (int argc, char * const * argv)
|
|||
{
|
||||
block.hashables.previous.qwords [0] += 1;
|
||||
auto begin1 (std::chrono::high_resolution_clock::now ());
|
||||
work.work_validate (block);
|
||||
for (uint64_t t (0); t < 1000000; ++t)
|
||||
{
|
||||
block.hashables.previous.qwords [0] += 1;
|
||||
block.block_work_set (t);
|
||||
work.work_validate (block);
|
||||
}
|
||||
auto end1 (std::chrono::high_resolution_clock::now ());
|
||||
std::cerr << boost::str (boost::format ("%|1$ 12d|\n") % std::chrono::duration_cast <std::chrono::microseconds> (end1 - begin1).count ());
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue