diff options
author | Felix Thomasmathibalan <felixjohnny.thomasmathibalan@arm.com> | 2023-09-27 17:46:17 +0100 |
---|---|---|
committer | felixjohnny.thomasmathibalan <felixjohnny.thomasmathibalan@arm.com> | 2023-09-28 12:08:05 +0000 |
commit | afd38f0c617d6f89b2b4532c6c44f116617e2b6f (patch) | |
tree | 03bc7d5a762099989b16a656fa8d397b490ed70e /src/graph/GraphContext.cpp | |
parent | bdcb4c148ee2fdeaaddf4cf1e57bbb0de02bb894 (diff) | |
download | ComputeLibrary-afd38f0c617d6f89b2b4532c6c44f116617e2b6f.tar.gz |
Apply clang-format on repository
Code is formatted as per a revised clang format configuration
file(not part of this delivery). Version 14.0.6 is used.
Exclusion List:
- files with .cl extension
- files that are not strictly C/C++ (e.g. Android.bp, Sconscript ...)
And the following directories
- compute_kernel_writer/validation/
- tests/
- include/
- src/core/NEON/kernels/convolution/
- src/core/NEON/kernels/arm_gemm/
- src/core/NEON/kernels/arm_conv/
- data/
There will be a follow up for formatting of .cl files and the
files under tests/ and compute_kernel_writer/validation/.
Signed-off-by: Felix Thomasmathibalan <felixjohnny.thomasmathibalan@arm.com>
Change-Id: Ib7eb1fcf4e7537b9feaefcfc15098a804a3fde0a
Reviewed-on: https://review.mlplatform.org/c/ml/ComputeLibrary/+/10391
Benchmark: Arm Jenkins <bsgcomp@arm.com>
Tested-by: Arm Jenkins <bsgcomp@arm.com>
Reviewed-by: Gunes Bayir <gunes.bayir@arm.com>
Diffstat (limited to 'src/graph/GraphContext.cpp')
-rw-r--r-- | src/graph/GraphContext.cpp | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/src/graph/GraphContext.cpp b/src/graph/GraphContext.cpp index 7b74c2fe0e..10850aa259 100644 --- a/src/graph/GraphContext.cpp +++ b/src/graph/GraphContext.cpp @@ -24,15 +24,14 @@ #include "arm_compute/graph/GraphContext.h" #include "arm_compute/graph.h" -#include "arm_compute/graph/Utils.h" #include "arm_compute/graph/backends/BackendRegistry.h" +#include "arm_compute/graph/Utils.h" namespace arm_compute { namespace graph { -GraphContext::GraphContext() - : _config(), _memory_managers(), _weights_managers() +GraphContext::GraphContext() : _config(), _memory_managers(), _weights_managers() { } @@ -56,7 +55,7 @@ void GraphContext::set_config(const GraphConfig &config) bool GraphContext::insert_memory_management_ctx(MemoryManagerContext &&memory_ctx) { Target target = memory_ctx.target; - if(target == Target::UNSPECIFIED || _memory_managers.find(target) != std::end(_memory_managers)) + if (target == Target::UNSPECIFIED || _memory_managers.find(target) != std::end(_memory_managers)) { return false; } @@ -79,7 +78,7 @@ bool GraphContext::insert_weights_management_ctx(WeightsManagerContext &&weights { Target target = weights_managers.target; - if(_weights_managers.find(target) != std::end(_weights_managers)) + if (_weights_managers.find(target) != std::end(_weights_managers)) { return false; } @@ -102,17 +101,17 @@ std::map<Target, WeightsManagerContext> &GraphContext::weights_managers() void GraphContext::finalize() { const size_t num_pools = 1; - for(auto &mm_obj : _memory_managers) + for (auto &mm_obj : _memory_managers) { ARM_COMPUTE_ERROR_ON(!mm_obj.second.allocator); // Finalize intra layer memory manager - if(mm_obj.second.intra_mm != nullptr) + if (mm_obj.second.intra_mm != nullptr) { mm_obj.second.intra_mm->populate(*mm_obj.second.allocator, num_pools); } // Finalize cross layer memory manager - if(mm_obj.second.cross_mm != nullptr) + if (mm_obj.second.cross_mm != nullptr) { mm_obj.second.cross_mm->populate(*mm_obj.second.allocator, num_pools); } |