From 6730fe9cbc195f054d697b25daba8516d70658e0 Mon Sep 17 00:00:00 2001 From: Jim Flynn Date: Thu, 10 Mar 2022 22:57:47 +0000 Subject: IVGCVSW-6842 Replace ARMNN_ASSERT with ARM_PIPE_ASSERT in profiling code Change-Id: Ie982ae603b7fb2793baf921232d32ce43f46d444 Signed-off-by: Jim Flynn --- src/profiling/ProfilingService.cpp | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'src/profiling/ProfilingService.cpp') diff --git a/src/profiling/ProfilingService.cpp b/src/profiling/ProfilingService.cpp index f0d668cc32..677158e64c 100644 --- a/src/profiling/ProfilingService.cpp +++ b/src/profiling/ProfilingService.cpp @@ -126,7 +126,7 @@ void ProfilingService::Update() try { // Setup the profiling connection - ARMNN_ASSERT(m_ProfilingConnectionFactory); + ARM_PIPE_ASSERT(m_ProfilingConnectionFactory); m_ProfilingConnection = m_ProfilingConnectionFactory->GetProfilingConnection(m_Options); } catch (const arm::pipe::ProfilingException& e) @@ -147,7 +147,7 @@ void ProfilingService::Update() // "NotConnected" state break; case ProfilingState::WaitingForAck: - ARMNN_ASSERT(m_ProfilingConnection); + ARM_PIPE_ASSERT(m_ProfilingConnection); // Start the command thread m_CommandHandler.Start(*m_ProfilingConnection); @@ -196,7 +196,7 @@ void ProfilingService::Disconnect() void ProfilingService::AddBackendProfilingContext(const std::string& backendId, std::shared_ptr profilingContext) { - ARMNN_ASSERT(profilingContext != nullptr); + ARM_PIPE_ASSERT(profilingContext != nullptr); // Register the backend counters m_MaxGlobalCounterId = profilingContext->RegisterCounters(m_MaxGlobalCounterId); m_BackendProfilingContexts.emplace(backendId, std::move(profilingContext)); @@ -230,7 +230,7 @@ uint32_t ProfilingService::GetAbsoluteCounterValue(uint16_t counterUid) const { CheckCounterUid(counterUid); std::atomic* counterValuePtr = m_CounterIndex.at(counterUid); - ARMNN_ASSERT(counterValuePtr); + ARM_PIPE_ASSERT(counterValuePtr); return counterValuePtr->load(std::memory_order::memory_order_relaxed); } @@ -238,7 +238,7 @@ uint32_t ProfilingService::GetDeltaCounterValue(uint16_t counterUid) { CheckCounterUid(counterUid); std::atomic* counterValuePtr = m_CounterIndex.at(counterUid); - ARMNN_ASSERT(counterValuePtr); + ARM_PIPE_ASSERT(counterValuePtr); const uint32_t counterValue = counterValuePtr->load(std::memory_order::memory_order_relaxed); SubtractCounterValue(counterUid, counterValue); return counterValue; @@ -280,7 +280,7 @@ void ProfilingService::SetCounterValue(uint16_t counterUid, uint32_t value) { CheckCounterUid(counterUid); std::atomic* counterValuePtr = m_CounterIndex.at(counterUid); - ARMNN_ASSERT(counterValuePtr); + ARM_PIPE_ASSERT(counterValuePtr); counterValuePtr->store(value, std::memory_order::memory_order_relaxed); } @@ -288,7 +288,7 @@ uint32_t ProfilingService::AddCounterValue(uint16_t counterUid, uint32_t value) { CheckCounterUid(counterUid); std::atomic* counterValuePtr = m_CounterIndex.at(counterUid); - ARMNN_ASSERT(counterValuePtr); + ARM_PIPE_ASSERT(counterValuePtr); return counterValuePtr->fetch_add(value, std::memory_order::memory_order_relaxed); } @@ -296,7 +296,7 @@ uint32_t ProfilingService::SubtractCounterValue(uint16_t counterUid, uint32_t va { CheckCounterUid(counterUid); std::atomic* counterValuePtr = m_CounterIndex.at(counterUid); - ARMNN_ASSERT(counterValuePtr); + ARM_PIPE_ASSERT(counterValuePtr); return counterValuePtr->fetch_sub(value, std::memory_order::memory_order_relaxed); } @@ -304,7 +304,7 @@ uint32_t ProfilingService::IncrementCounterValue(uint16_t counterUid) { CheckCounterUid(counterUid); std::atomic* counterValuePtr = m_CounterIndex.at(counterUid); - ARMNN_ASSERT(counterValuePtr); + ARM_PIPE_ASSERT(counterValuePtr); return counterValuePtr->operator++(std::memory_order::memory_order_relaxed); } -- cgit v1.2.1