aboutsummaryrefslogtreecommitdiff
path: root/src/profiling/test/ProfilingTests.cpp
diff options
context:
space:
mode:
authorJan Eilers <jan.eilers@arm.com>2020-03-26 12:04:54 +0000
committerJan Eilers <jan.eilers@arm.com>2020-03-26 12:04:54 +0000
commita10e2a26b20b124aaa03f20554172d88683257f7 (patch)
tree6ca5740a267857e94aa064500e582667ff2ed325 /src/profiling/test/ProfilingTests.cpp
parentaf1c63b98df76caa89ecc8d599de5fe1e0b60d88 (diff)
downloadarmnn-a10e2a26b20b124aaa03f20554172d88683257f7.tar.gz
IVGCVSW-4526 Fix UnitTest errors when running on raspberry pi
* The std::thread::id is included in some timeline packages of the profiler. But the size of thread::id is platform dependent. That's why some tests expected a wrong package size Signed-off-by: Jan Eilers <jan.eilers@arm.com> Change-Id: I4794ebbdda2d75ed5be7112f6a3bf2e5f14f221b
Diffstat (limited to 'src/profiling/test/ProfilingTests.cpp')
-rw-r--r--src/profiling/test/ProfilingTests.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/profiling/test/ProfilingTests.cpp b/src/profiling/test/ProfilingTests.cpp
index a631cb2356..74b93d7c4f 100644
--- a/src/profiling/test/ProfilingTests.cpp
+++ b/src/profiling/test/ProfilingTests.cpp
@@ -692,7 +692,7 @@ BOOST_AUTO_TEST_CASE(CheckProfilingServiceCounterValues)
ProfilingService* profilingServicePtr = &profilingService;
std::vector<std::thread> writers;
- for (int i = 0; i < 100; ++i)
+ for (int i = 0; i < 10; ++i)
{
// Increment and decrement the first counter
writers.push_back(std::thread(&ProfilingService::IncrementCounterValue,
@@ -719,7 +719,7 @@ BOOST_AUTO_TEST_CASE(CheckProfilingServiceCounterValues)
BOOST_CHECK(counterValue ==
(profilingService.GetCounterValue(armnn::profiling::UNREGISTERED_BACKENDS)
- profilingService.GetCounterValue(armnn::profiling::REGISTERED_BACKENDS)));
- BOOST_CHECK(profilingService.GetCounterValue(armnn::profiling::INFERENCES_RUN) == 500);
+ BOOST_CHECK(profilingService.GetCounterValue(armnn::profiling::INFERENCES_RUN) == 50);
BOOST_CHECK_NO_THROW(profilingService.SetCounterValue(armnn::profiling::UNREGISTERED_BACKENDS, 4));
BOOST_CHECK_NO_THROW(counterValue = profilingService.GetCounterValue(armnn::profiling::UNREGISTERED_BACKENDS));