aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnthony Barbier <anthony.barbier@arm.com>2018-03-29 11:38:22 +0100
committerAnthony Barbier <anthony.barbier@arm.com>2018-11-02 16:49:16 +0000
commit7db3a30cd15659af75938cd964eebb17a12c6e81 (patch)
tree5f1f771517c353c88466b7570153e7f7ee25797d
parent7f7936a0fd18043e6acfe444cef9b44933af6853 (diff)
downloadComputeLibrary-7db3a30cd15659af75938cd964eebb17a12c6e81.tar.gz
COMPMID-959 Fix SVM and AlexNet Code formatting
Change-Id: I4d2f67206ca56e6468a6e1491ca93bdde31c32ff Reviewed-on: https://eu-gerrit-1.euhpc.arm.com/126278 Reviewed-by: Georgios Pinitas <georgios.pinitas@arm.com> Tested-by: Jenkins <bsgcomp@arm.com>
-rw-r--r--arm_compute/runtime/CL/SVMMemory.h51
-rw-r--r--examples/graph_alexnet.cpp4
2 files changed, 28 insertions, 27 deletions
diff --git a/arm_compute/runtime/CL/SVMMemory.h b/arm_compute/runtime/CL/SVMMemory.h
index 1c90c274d3..9029388c70 100644
--- a/arm_compute/runtime/CL/SVMMemory.h
+++ b/arm_compute/runtime/CL/SVMMemory.h
@@ -26,31 +26,32 @@
namespace arm_compute
{
- class SVMMemory final
+class SVMMemory final
+{
+public:
+ SVMMemory() = default;
+ SVMMemory(void *ptr, bool fine_grain)
+ : _ptr(ptr), _fine_grain(fine_grain), _size(0)
+ {
+ }
+ void *ptr() const
+ {
+ return _ptr;
+ }
+ bool fine_grain() const
{
- public:
- SVMMemory() = default;
- SVMMemory(void *ptr, bool fine_grain)
- : _ptr(ptr), _fine_grain(fine_grain), _size(0)
- {
- }
- void *ptr() const
- {
- return _ptr;
- }
- bool fine_grain() const
- {
- return _fine_grain;
- }
- size_t size() const
- {
- return _size;
- }
- void *allocate(cl_context context, size_t size, cl_svm_mem_flags flags, cl_uint alignment);
- private:
- void *_ptr{ nullptr };
- bool _fine_grain{ false };
- size_t _size{ 0 };
- };
+ return _fine_grain;
+ }
+ size_t size() const
+ {
+ return _size;
+ }
+ void *allocate(cl_context context, size_t size, cl_svm_mem_flags flags, cl_uint alignment);
+
+private:
+ void *_ptr{ nullptr };
+ bool _fine_grain{ false };
+ size_t _size{ 0 };
+};
}
#endif /* __ARM_COMPUTE_SVMMEMORY_H__ */
diff --git a/examples/graph_alexnet.cpp b/examples/graph_alexnet.cpp
index 885db337e9..418d1ea071 100644
--- a/examples/graph_alexnet.cpp
+++ b/examples/graph_alexnet.cpp
@@ -53,8 +53,8 @@ public:
std::unique_ptr<IPreprocessor> preprocessor = arm_compute::support::cpp14::make_unique<CaffePreproccessor>(mean_rgb);
// Set target. 0 (NEON), 1 (OpenCL), 2 (OpenCL with Tuner). By default it is NEON
- const int target = argc > 1 ? std::strtol(argv[1], nullptr, 10) : 0;
- Target target_hint = set_target_hint2(target);
+ const int target = argc > 1 ? std::strtol(argv[1], nullptr, 10) : 0;
+ Target target_hint = set_target_hint2(target);
// TODO (geopin01) : Get GPU target somehow and set gemm also for midgard ?
const bool is_gemm_convolution5x5 = (target_hint == Target::NEON);