MCPcopy Create free account
hub / github.com/Beckhoff/ADS / testParallelReadAndWrite

Method testParallelReadAndWrite

AdsLibOOITest/main.cpp:560–576  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

558 }
559
560 void testParallelReadAndWrite(const std::string &testname)
561 {
562 std::thread threads[96];
563 const auto start = std::chrono::high_resolution_clock::now();
564 for (auto &t : threads) {
565 t = std::thread(&TestAdsPerformance::Read, this, 1024);
566 }
567 for (auto &t : threads) {
568 t.join();
569 }
570 const auto end = std::chrono::high_resolution_clock::now();
571 const auto tmms =
572 std::chrono::duration_cast<std::chrono::milliseconds>(
573 end - start)
574 .count();
575 out << testname << " took " << tmms << "ms\n";
576 }
577
578 void testEndurance(const std::string &testname)
579 {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected