Integrate improved pooling layer on NEON

Resolves COMPMID-4035

Change-Id: I559f8c4208fba9193dfe5012f03ddaf26c746215
Signed-off-by: Michele Di Giorgio <michele.digiorgio@arm.com>
Reviewed-on: https://review.mlplatform.org/c/ml/ComputeLibrary/+/4855
Tested-by: Arm Jenkins <bsgcomp@arm.com>
Reviewed-by: Georgios Pinitas <georgios.pinitas@arm.com>
Comments-Addressed: Arm Jenkins <bsgcomp@arm.com>
diff --git a/arm_compute/runtime/NEON/functions/NEPoolingLayer.h b/arm_compute/runtime/NEON/functions/NEPoolingLayer.h
index b45290f..d239138 100644
--- a/arm_compute/runtime/NEON/functions/NEPoolingLayer.h
+++ b/arm_compute/runtime/NEON/functions/NEPoolingLayer.h
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2017-2020 Arm Limited.
+ * Copyright (c) 2017-2021 Arm Limited.
  *
  * SPDX-License-Identifier: MIT
  *
@@ -24,9 +24,10 @@
 #ifndef ARM_COMPUTE_NEPOOLINGLAYER_H
 #define ARM_COMPUTE_NEPOOLINGLAYER_H
 
-#include "arm_compute/runtime/IFunction.h"
-
 #include "arm_compute/core/Types.h"
+#include "arm_compute/runtime/IFunction.h"
+#include "arm_compute/runtime/IMemoryManager.h"
+
 #include <memory>
 
 namespace arm_compute
@@ -35,17 +36,19 @@
 class ITensorInfo;
 class NEPoolingLayerKernel;
 class NEFillBorderKernel;
+class NEPoolingAssemblyDispatch;
 
 /** Basic function to simulate a pooling layer with the specified pooling operation. This function calls the following NEON kernels:
  *
  * -# @ref NEFillBorderKernel (executed if padding size is different from zero)
  * -# @ref NEPoolingLayerKernel
+ * -# @ref NEPoolingAssemblyDispatch
  */
 class NEPoolingLayer : public IFunction
 {
 public:
     /** Constructor */
-    NEPoolingLayer();
+    NEPoolingLayer(std::shared_ptr<IMemoryManager> memory_manager = nullptr);
     /** Prevent instances of this class from being copied (As this class contains pointers) */
     NEPoolingLayer(const NEPoolingLayer &) = delete;
     /** Prevent instances of this class from being copied (As this class contains pointers) */
@@ -83,10 +86,14 @@
     void run() override;
 
 private:
-    std::unique_ptr<NEPoolingLayerKernel> _pooling_layer_kernel;
-    std::unique_ptr<NEFillBorderKernel>   _border_handler;
-    bool                                  _is_global_pooling_layer;
-    DataLayout                            _data_layout;
+    std::shared_ptr<IMemoryManager> _memory_manager;
+
+    std::unique_ptr<NEPoolingLayerKernel>      _pooling_layer_kernel;
+    std::unique_ptr<NEFillBorderKernel>        _border_handler;
+    std::unique_ptr<NEPoolingAssemblyDispatch> _asm_glue;
+
+    bool       _is_global_pooling_layer;
+    DataLayout _data_layout;
 };
 }
 #endif /* ARM_COMPUTE_NEPOOLINGLAYER_H */