IVGCVSW-4317 Implement the Profiling Context Initialisation

* Call CreateBackendProfilingContext on each backend from Runtime passing
  an instance of the BackendProfiling interface.
* Modify the signature of CreateBackendProfilingContext to remove const
  and return a shared_ptr to BackendProfilingContext
* Add concrete BackendProfiling class.
* Store BackendProfilingContexts in Profiling service.

Signed-off-by: Colm Donelan <Colm.Donelan@arm.com>
Change-Id: I975eaa2093ae91fa623835f65f9e5b25eb65117a
diff --git a/src/backends/backendsCommon/test/MockBackend.hpp b/src/backends/backendsCommon/test/MockBackend.hpp
index 3fe3100..d1a0082 100644
--- a/src/backends/backendsCommon/test/MockBackend.hpp
+++ b/src/backends/backendsCommon/test/MockBackend.hpp
@@ -5,14 +5,15 @@
 
 #pragma once
 
+#include <LayerSupportCommon.hpp>
 #include <armnn/backends/IBackendInternal.hpp>
 #include <armnn/backends/OptimizationViews.hpp>
-#include <LayerSupportCommon.hpp>
 #include <backendsCommon/LayerSupportBase.hpp>
 
 namespace armnn
 {
 
+
 class MockBackend : public IBackendInternal
 {
 public:
@@ -20,17 +21,20 @@
     ~MockBackend() = default;
 
     static const BackendId& GetIdStatic();
-    const BackendId& GetId() const override { return GetIdStatic(); }
+    const BackendId& GetId() const override
+    {
+        return GetIdStatic();
+    }
 
     IBackendInternal::IMemoryManagerUniquePtr CreateMemoryManager() const override;
 
-    IBackendInternal::IWorkloadFactoryPtr CreateWorkloadFactory(
-        const IBackendInternal::IMemoryManagerSharedPtr& memoryManager = nullptr) const override;
+    IBackendInternal::IWorkloadFactoryPtr
+        CreateWorkloadFactory(const IBackendInternal::IMemoryManagerSharedPtr& memoryManager = nullptr) const override;
 
     IBackendInternal::IBackendContextPtr CreateBackendContext(const IRuntime::CreationOptions&) const override;
-    IBackendInternal::IBackendProfilingContextPtr CreateBackendProfilingContext(
-        const IRuntime::CreationOptions& creationOptions,
-        armnn::profiling::IBackendProfiling& backendProfiling) const override;
+    IBackendInternal::IBackendProfilingContextPtr
+        CreateBackendProfilingContext(const IRuntime::CreationOptions& creationOptions,
+                                      IBackendProfilingPtr& backendProfiling) override;
 
     IBackendInternal::Optimizations GetOptimizations() const override;
     IBackendInternal::ILayerSupportSharedPtr GetLayerSupport() const override;
@@ -38,7 +42,8 @@
     OptimizationViews OptimizeSubgraphView(const SubgraphView& subgraph) const override;
 };
 
-class MockLayerSupport : public LayerSupportBase {
+class MockLayerSupport : public LayerSupportBase
+{
 public:
     bool IsInputSupported(const TensorInfo& /*input*/,
                           Optional<std::string&> /*reasonIfUnsupported = EmptyOptional()*/) const override
@@ -47,7 +52,7 @@
     }
 
     bool IsOutputSupported(const TensorInfo& /*input*/,
-                          Optional<std::string&> /*reasonIfUnsupported = EmptyOptional()*/) const override
+                           Optional<std::string&> /*reasonIfUnsupported = EmptyOptional()*/) const override
     {
         return true;
     }
@@ -71,4 +76,4 @@
     }
 };
 
-} // namespace armnn
+}    // namespace armnn