aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJim Flynn <jim.flynn@arm.com>2022-03-13 16:57:04 +0000
committerJim Flynn <jim.flynn@arm.com>2022-03-13 16:57:04 +0000
commit0a013a779b2697ac0a4c9d3e91cb2d627dfb342d (patch)
tree20cea444df28e9aad62f591f8218188fe788bd2a
parent6c9f17dc5fe58e23db0ba591302168766b38ab2a (diff)
downloadarmnn-0a013a779b2697ac0a4c9d3e91cb2d627dfb342d.tar.gz
IVGCVSW-6849 Change ARMNN_NO_CONVERSION_WARN_BEGIN/END to ARM_PIPE_NO_CONVERSION_WARN_BEGIN/END in the profiling code
Change-Id: Id5571f9847289692f968ad30ceab064e96693cac Signed-off-by: Jim Flynn <jim.flynn@arm.com>
-rw-r--r--src/profiling/SendCounterPacket.cpp16
-rw-r--r--src/profiling/SendThread.cpp1
-rw-r--r--src/profiling/test/ProfilingMocks.hpp1
-rw-r--r--src/profiling/test/ProfilingTests.cpp1
-rw-r--r--src/profiling/test/SendCounterPacketTests.cpp14
-rw-r--r--src/profiling/test/SendCounterPacketTests.hpp1
6 files changed, 14 insertions, 20 deletions
diff --git a/src/profiling/SendCounterPacket.cpp b/src/profiling/SendCounterPacket.cpp
index 6a30c65936..4586d9acb8 100644
--- a/src/profiling/SendCounterPacket.cpp
+++ b/src/profiling/SendCounterPacket.cpp
@@ -6,16 +6,14 @@
#include "SendCounterPacket.hpp"
#include <common/include/Assert.hpp>
+#include <common/include/Conversion.hpp>
#include <common/include/Constants.hpp>
#include <common/include/EncodeVersion.hpp>
#include <common/include/ProfilingException.hpp>
#include <common/include/SwTrace.hpp>
-#include <armnn/Conversion.hpp>
#include <Processes.hpp>
-#include <armnn/utility/NumericCast.hpp>
-
#include <fmt/format.h>
#include <cstring>
@@ -275,7 +273,7 @@ bool SendCounterPacket::CreateCategoryRecord(const CategoryPtr& category,
// Allocate the necessary space for the category record
categoryRecord.resize(categoryRecordSize);
- ARMNN_NO_CONVERSION_WARN_BEGIN
+ ARM_PIPE_NO_CONVERSION_WARN_BEGIN
// Create the category record
categoryRecord[0] = categoryRecordWord1; // event_count + reserved
categoryRecord[1] = categoryRecordWord2; // event_pointer_table_offset
@@ -290,7 +288,7 @@ bool SendCounterPacket::CreateCategoryRecord(const CategoryPtr& category,
std::copy(eventRecord.begin(), eventRecord.end(), offset); // event_record
offset += eventRecord.size();
}
- ARMNN_NO_CONVERSION_WARN_END
+ ARM_PIPE_NO_CONVERSION_WARN_END
return true;
}
@@ -523,7 +521,7 @@ bool SendCounterPacket::CreateEventRecord(const CounterPtr& counter,
// Allocate the space for the event record
eventRecord.resize(eventRecordSize);
- ARMNN_NO_CONVERSION_WARN_BEGIN
+ ARM_PIPE_NO_CONVERSION_WARN_BEGIN
// Create the event record
eventRecord[0] = eventRecordWord0; // max_counter_uid + counter_uid
eventRecord[1] = eventRecordWord1; // device + counter_set
@@ -542,7 +540,7 @@ bool SendCounterPacket::CreateEventRecord(const CounterPtr& counter,
offset += counterDescriptionBuffer.size();
std::copy(counterUnitsBuffer.begin(), counterUnitsBuffer.end(), offset); // units
}
- ARMNN_NO_CONVERSION_WARN_END
+ ARM_PIPE_NO_CONVERSION_WARN_END
return true;
}
@@ -762,7 +760,7 @@ void SendCounterPacket::SendCounterDirectoryPacket(const ICounterDirectory& coun
bodyHeaderWord5 // categories_pointer_table_offset
};
- ARMNN_NO_CONVERSION_WARN_BEGIN
+ ARM_PIPE_NO_CONVERSION_WARN_BEGIN
// Create the counter directory packet
auto counterDirectoryPacketOffset = counterDirectoryPacket.begin();
// packet_header
@@ -798,7 +796,7 @@ void SendCounterPacket::SendCounterDirectoryPacket(const ICounterDirectory& coun
std::copy(categoryRecord.begin(), categoryRecord.end(), counterDirectoryPacketOffset); // category_record
counterDirectoryPacketOffset += categoryRecord.size();
}
- ARMNN_NO_CONVERSION_WARN_END
+ ARM_PIPE_NO_CONVERSION_WARN_END
// Calculate the total size in bytes of the counter directory packet
uint32_t totalSize = arm::pipe::numeric_cast<uint32_t>(counterDirectoryPacketSize * uint32_t_size);
diff --git a/src/profiling/SendThread.cpp b/src/profiling/SendThread.cpp
index c09a656cd2..1459ae5499 100644
--- a/src/profiling/SendThread.cpp
+++ b/src/profiling/SendThread.cpp
@@ -6,7 +6,6 @@
#include "SendThread.hpp"
#include "ProfilingUtils.hpp"
-#include <armnn/Conversion.hpp>
#include <common/include/NumericCast.hpp>
#include <common/include/ProfilingException.hpp>
diff --git a/src/profiling/test/ProfilingMocks.hpp b/src/profiling/test/ProfilingMocks.hpp
index 4af2b6064e..4da167a7ec 100644
--- a/src/profiling/test/ProfilingMocks.hpp
+++ b/src/profiling/test/ProfilingMocks.hpp
@@ -14,7 +14,6 @@
#include <SendThread.hpp>
#include <armnn/Optional.hpp>
-#include <armnn/Conversion.hpp>
#include <common/include/Assert.hpp>
#include <common/include/IgnoreUnused.hpp>
diff --git a/src/profiling/test/ProfilingTests.cpp b/src/profiling/test/ProfilingTests.cpp
index 9c3007b017..08513182b5 100644
--- a/src/profiling/test/ProfilingTests.cpp
+++ b/src/profiling/test/ProfilingTests.cpp
@@ -25,7 +25,6 @@
#include <SendThread.hpp>
#include <SendTimelinePacket.hpp>
-#include <armnn/Conversion.hpp>
#include <armnn/Utils.hpp>
#include <armnn/profiling/ArmNNProfiling.hpp>
diff --git a/src/profiling/test/SendCounterPacketTests.cpp b/src/profiling/test/SendCounterPacketTests.cpp
index e94687119d..4ae2c5562b 100644
--- a/src/profiling/test/SendCounterPacketTests.cpp
+++ b/src/profiling/test/SendCounterPacketTests.cpp
@@ -13,10 +13,10 @@
#include <SendCounterPacket.hpp>
#include <Processes.hpp>
-#include <armnn/Conversion.hpp>
#include <armnn/Utils.hpp>
#include <common/include/Assert.hpp>
+#include <common/include/Conversion.hpp>
#include <common/include/Constants.hpp>
#include <common/include/EncodeVersion.hpp>
#include <common/include/NumericCast.hpp>
@@ -605,7 +605,7 @@ TEST_CASE("CreateEventRecordTest")
CHECK(eventRecordWord2[1] == counterInterpolation); // interpolation
CHECK(std::memcmp(eventRecordWord34, &counterMultiplier, sizeof(counterMultiplier)) == 0); // multiplier
- ARMNN_NO_CONVERSION_WARN_BEGIN
+ ARM_PIPE_NO_CONVERSION_WARN_BEGIN
uint32_t eventRecordBlockSize = 8u * sizeof(uint32_t);
uint32_t counterNameOffset = eventRecordBlockSize; // The name is the first item in pool
uint32_t counterDescriptionOffset = counterNameOffset + // Counter name offset
@@ -620,7 +620,7 @@ TEST_CASE("CreateEventRecordTest")
1u + // Null-terminator
2u; // Rounding to the next word
- ARMNN_NO_CONVERSION_WARN_END
+ ARM_PIPE_NO_CONVERSION_WARN_END
CHECK(eventRecord[5] == counterNameOffset); // name_offset
CHECK(eventRecord[6] == counterDescriptionOffset); // description_offset
@@ -729,7 +729,7 @@ TEST_CASE("CreateEventRecordNoUnitsTest")
CHECK(eventRecordWord2[1] == counterInterpolation); // interpolation
CHECK(std::memcmp(eventRecordWord34, &counterMultiplier, sizeof(counterMultiplier)) == 0); // multiplier
- ARMNN_NO_CONVERSION_WARN_BEGIN
+ ARM_PIPE_NO_CONVERSION_WARN_BEGIN
uint32_t eventRecordBlockSize = 8u * sizeof(uint32_t);
uint32_t counterNameOffset = eventRecordBlockSize; // The name is the first item in pool
uint32_t counterDescriptionOffset = counterNameOffset + // Counter name offset
@@ -737,7 +737,7 @@ TEST_CASE("CreateEventRecordNoUnitsTest")
counterName.size() + // 18u
1u + // Null-terminator
1u; // Rounding to the next word
- ARMNN_NO_CONVERSION_WARN_END
+ ARM_PIPE_NO_CONVERSION_WARN_END
CHECK(eventRecord[5] == counterNameOffset); // name_offset
CHECK(eventRecord[6] == counterDescriptionOffset); // description_offset
@@ -964,12 +964,12 @@ TEST_CASE("CreateCategoryRecordTest")
size_t uint32_t_size = sizeof(uint32_t);
- ARMNN_NO_CONVERSION_WARN_BEGIN
+ ARM_PIPE_NO_CONVERSION_WARN_BEGIN
uint32_t categoryRecordBlockSize = 3u * uint32_t_size;
uint32_t eventPointerTableOffset = categoryRecordBlockSize; // The event pointer table is the first item in pool
uint32_t categoryNameOffset = eventPointerTableOffset + // Event pointer table offset
categoryEventCount * uint32_t_size; // The size of the event pointer table
- ARMNN_NO_CONVERSION_WARN_END
+ ARM_PIPE_NO_CONVERSION_WARN_END
CHECK(categoryRecord[1] == eventPointerTableOffset); // event_pointer_table_offset
CHECK(categoryRecord[2] == categoryNameOffset); // name_offset
diff --git a/src/profiling/test/SendCounterPacketTests.hpp b/src/profiling/test/SendCounterPacketTests.hpp
index de731c8d7b..1f1c3f0b27 100644
--- a/src/profiling/test/SendCounterPacketTests.hpp
+++ b/src/profiling/test/SendCounterPacketTests.hpp
@@ -11,7 +11,6 @@
#include <IProfilingConnectionFactory.hpp>
#include <armnn/Optional.hpp>
-#include <armnn/Conversion.hpp>
#include <common/include/IgnoreUnused.hpp>
#include <common/include/NumericCast.hpp>