Commit f1c8ee3d authored by Dmitry I. Lyakh's avatar Dmitry I. Lyakh
Browse files

cuQuantum backend seems to work, but reports weird flop count ...


Signed-off-by: default avatarDmitry I. Lyakh <quant4me@gmail.com>
parent 2108557e
......@@ -3789,9 +3789,9 @@ TEST(NumServerTester, CuTensorNet) {
const auto TENS_ELEM_TYPE = TensorElementType::REAL32;
const int NUM_REPEATS = 1;
const int NUM_REPEATS = 3;
exatn::resetLoggingLevel(2,2); //debug
//exatn::resetLoggingLevel(2,2); //debug
bool success = true;
......@@ -3808,7 +3808,7 @@ TEST(NumServerTester, CuTensorNet) {
success = exatn::initTensor("D",0.0); assert(success);
success = exatn::sync(); assert(success);
exatn::switchComputationalBackend("cuquantum");
exatn::switchComputationalBackend("default"); //{default|cuquantum}
//Contract tensor network:
int num_repeats = NUM_REPEATS;
......@@ -3820,7 +3820,8 @@ TEST(NumServerTester, CuTensorNet) {
success = exatn::sync("D",true); assert(success);
auto duration = exatn::Timer::timeInSecHR(time_start);
flops = exatn::getTotalFlopCount() - flops;
std::cout << "Duration = " << duration << " s; Performance = " << (flops / (1e9 * duration)) << " Gflop/s\n";
std::cout << "Duration = " << duration << " s; GFlop count = " << flops/1e9
<< "; Performance = " << (flops / (1e9 * duration)) << " Gflop/s\n";
}
//std::this_thread::sleep_for(std::chrono::microseconds(1000000));
......
......@@ -168,6 +168,9 @@ CuQuantumExecutor::~CuQuantumExecutor()
HANDLE_CTN_ERROR(cutensornetDestroy((cutensornetHandle_t)(gpu.second.cutn_handle)));
}
std::cout << "#DEBUG(exatn::runtime::CuQuantumExecutor): Destroyed cuTensorNet contexts for all available GPUs" << std::endl;
std::cout << "#MSG(exatn::cuQuantum): Statistics across all GPU devices:\n";
std::cout << " Number of Flops processed: " << flops_ << std::endl;
std::cout << "#END_MSG\n";
gpu_attr_.clear();
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment