diff options
author | Vidhya Sudhan Loganathan <vidhyasudhan.loganathan@arm.com> | 2019-04-25 09:27:24 +0100 |
---|---|---|
committer | Gian Marco Iodice <gianmarco.iodice@arm.com> | 2019-04-25 16:18:58 +0000 |
commit | 050471e40fc58cb5ea745701a43ec5b2b9586b81 (patch) | |
tree | 0ee684bcc93fae693686c391e42a2b824705aeb1 /arm_compute/graph | |
parent | d038dafe3810d22c8664ceef4fe49aad77abdbd1 (diff) | |
download | ComputeLibrary-050471e40fc58cb5ea745701a43ec5b2b9586b81.tar.gz |
COMPMID-1974 : Extend CLTuner to support different of level of tuning
Change-Id: I52e4a00a25e7f7a17050038cee7c30e508553722
Signed-off-by: Vidhya Sudhan Loganathan <vidhyasudhan.loganathan@arm.com>
Reviewed-on: https://review.mlplatform.org/c/977
Comments-Addressed: Pablo Marquez <pablo.tello@arm.com>
Reviewed-by: Gian Marco Iodice <gianmarco.iodice@arm.com>
Tested-by: Arm Jenkins <bsgcomp@arm.com>
Reviewed-by: Georgios Pinitas <georgios.pinitas@arm.com>
Comments-Addressed: Arm Jenkins <bsgcomp@arm.com>
Diffstat (limited to 'arm_compute/graph')
-rw-r--r-- | arm_compute/graph/Types.h | 4 | ||||
-rw-r--r-- | arm_compute/graph/backends/CL/CLDeviceBackend.h | 7 |
2 files changed, 9 insertions, 2 deletions
diff --git a/arm_compute/graph/Types.h b/arm_compute/graph/Types.h index 582e6f6434..4d9e031b91 100644 --- a/arm_compute/graph/Types.h +++ b/arm_compute/graph/Types.h @@ -26,6 +26,7 @@ #include "arm_compute/core/Error.h" #include "arm_compute/core/Types.h" +#include "arm_compute/runtime/CL/CLTunerTypes.h" #include <limits> #include <string> @@ -34,6 +35,7 @@ namespace arm_compute { namespace graph { +using arm_compute::CLTunerMode; using arm_compute::Status; using arm_compute::Coordinates; @@ -71,13 +73,13 @@ constexpr EdgeID EmptyEdgeID = std::numeric_limits<EdgeID>::max(); // Forward declarations class TensorDescriptor; - /** Graph configuration structure */ struct GraphConfig { bool use_function_memory_manager{ true }; /**< Use a memory manager to manage per-funcion auxilary memory */ bool use_transition_memory_manager{ true }; /**< Use a memory manager to manager transition buffer memory */ bool use_tuner{ false }; /**< Use a tuner in tunable backends */ + CLTunerMode tuner_mode{ CLTunerMode::EXHAUSTIVE }; /**< Tuner mode to be used by the CL tuner */ int num_threads{ -1 }; /**< Number of threads to use (thread capable backends), if 0 the backend will auto-initialize, if -1 the backend will stay as it is. */ std::string tuner_file{ "acl_tuner.csv" }; /**< File to load/store tuning values from */ }; diff --git a/arm_compute/graph/backends/CL/CLDeviceBackend.h b/arm_compute/graph/backends/CL/CLDeviceBackend.h index 49e7596d58..afe01fff70 100644 --- a/arm_compute/graph/backends/CL/CLDeviceBackend.h +++ b/arm_compute/graph/backends/CL/CLDeviceBackend.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2018 ARM Limited. + * Copyright (c) 2018-2019 ARM Limited. * * SPDX-License-Identifier: MIT * @@ -50,6 +50,11 @@ public: * @param[in] enable_tuning Enables tuning if false else true */ void set_kernel_tuning(bool enable_tuning); + /** Set kernel tuning mode + * + * @param[in] tuning_mode Indicates how exhaustive the search for the optimal LWS should be while tuning + */ + void set_kernel_tuning_mode(CLTunerMode tuning_mode); // Inherited overridden methods void initialize_backend() override; |