Initialize unitialized M parameter in NEGEMMAssemblyDispatch
authorGeorgios Pinitas <georgios.pinitas@arm.com>
Sat, 21 Nov 2020 02:49:11 +0000 (02:49 +0000)
committerMichele Di Giorgio <michele.digiorgio@arm.com>
Mon, 23 Nov 2020 11:47:38 +0000 (11:47 +0000)
Resolves: COMPMID-3991

Signed-off-by: Georgios Pinitas <georgios.pinitas@arm.com>
Change-Id: I353ad84833ce25e1adadb980f46b95de63dd6c62
Reviewed-on: https://review.mlplatform.org/c/ml/ComputeLibrary/+/4522
Tested-by: Arm Jenkins <bsgcomp@arm.com>
Reviewed-by: Michele Di Giorgio <michele.digiorgio@arm.com>
Comments-Addressed: Arm Jenkins <bsgcomp@arm.com>
(cherry picked from commit 71696baa30fd2cb9ac7493937e65abfb16daa16e)
Reviewed-on: https://review.mlplatform.org/c/ml/ComputeLibrary/+/4168
Tested-by: Michele Di Giorgio <michele.digiorgio@arm.com>
src/runtime/NEON/functions/NEGEMMAssemblyDispatch.cpp

index 400fa64438990d56b5dfb67be2ffe1c12ed9e5ae..f6739ee925c88d7d3abd02347c992b3f634bd314 100644 (file)
@@ -61,6 +61,7 @@ Params extract_parameters(const ITensor *a, const ITensor *b, const ITensor *d,
     ARM_COMPUTE_ERROR_ON_NULLPTR(a, b, d);
 
     Params p;
+    p.M        = d->info()->tensor_shape().y();
     p.K        = a->info()->tensor_shape().x();
     p.N        = d->info()->tensor_shape().x();
     p.multis   = 1;
@@ -74,7 +75,6 @@ Params extract_parameters(const ITensor *a, const ITensor *b, const ITensor *d,
     }
     else
     {
-        p.M       = d->info()->tensor_shape().y();
         p.multis  = b->info()->tensor_shape().z();
         p.batches = d->info()->tensor_shape().total_size_upper(2) / p.multis; //COMPMID-1423: Agree on and document the layout of gemm inputs/outputs
     }