COMPMID-3467: Zero-initialize std::array in ndrange.hpp
authorGeorgios Pinitas <georgios.pinitas@arm.com>
Mon, 11 May 2020 11:29:03 +0000 (12:29 +0100)
committerGeorgios Pinitas <georgios.pinitas@arm.com>
Mon, 11 May 2020 16:07:49 +0000 (16:07 +0000)
Fix uninitialized variable warning.

Signed-off-by: Georgios Pinitas <georgios.pinitas@arm.com>
Change-Id: Ifeabc68e2ed3bc35b6cb68890716cceea6b519db
Reviewed-on: https://review.mlplatform.org/c/ml/ComputeLibrary/+/3170
Reviewed-by: Michele Di Giorgio <michele.digiorgio@arm.com>
Comments-Addressed: Arm Jenkins <bsgcomp@arm.com>
Tested-by: Arm Jenkins <bsgcomp@arm.com>
src/core/NEON/kernels/arm_gemm/ndrange.hpp

index 0c068db0113dad6064cd3db05a218e89e71a76db..4ff83fbc51959fe0ea95b6067c2f66b4505a100b 100644 (file)
@@ -101,7 +101,7 @@ public:
     }
 
     NDRange(const std::array<unsigned int, D>& n)
-    : m_sizes{n}
+    : m_sizes(n)
     {
         unsigned int t=1;
 
@@ -139,7 +139,7 @@ public:
     NDCoordinate(const NDCoordinate& rhs)           =default;
     NDCoordinate(const std::initializer_list<std::pair<int_t, int_t>>& list)
     {
-        std::array<int_t, N> sizes;
+        std::array<int_t, N> sizes{};
 
         std::size_t i = 0;
         for(auto& p : list) {