blob: 9c8eaf27330b5e8df73aac3561f14027d82acd53 [file] [log] [blame]
Vidhya Sudhan Loganathand646ae12018-11-19 15:18:20 +00001///
2/// Copyright (c) 2017-2018 ARM Limited.
3///
4/// SPDX-License-Identifier: MIT
5///
6/// Permission is hereby granted, free of charge, to any person obtaining a copy
7/// of this software and associated documentation files (the "Software"), to
8/// deal in the Software without restriction, including without limitation the
9/// rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
10/// sell copies of the Software, and to permit persons to whom the Software is
11/// furnished to do so, subject to the following conditions:
12///
13/// The above copyright notice and this permission notice shall be included in all
14/// copies or substantial portions of the Software.
15///
16/// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17/// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18/// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19/// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20/// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21/// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22/// SOFTWARE.
23///
Anthony Barbier3762e742018-03-02 11:49:33 +000024namespace arm_compute
25{
Anthony Barbier6ff3b192017-09-04 18:44:23 +010026/** @mainpage Introduction
27
28@tableofcontents
29
30The Computer Vision and Machine Learning library is a set of functions optimised for both ARM CPUs and GPUs using SIMD technologies.
31
32Several builds of the library are available using various configurations:
33 - OS: Linux, Android or bare metal.
34 - Architecture: armv7a (32bit) or arm64-v8a (64bit)
Anthony Barbier20dbb822017-12-13 21:19:39 +000035 - Technology: NEON / OpenCL / GLES_COMPUTE / NEON and OpenCL and GLES_COMPUTE
Anthony Barbier6ff3b192017-09-04 18:44:23 +010036 - Debug / Asserts / Release: Use a build with asserts enabled to debug your application and enable extra validation. Once you are sure your application works as expected you can switch to a release build of the library for maximum performance.
37
38@section S0_1_contact Contact / Support
39
40Please email developer@arm.com
41
42In order to facilitate the work of the support team please provide the build information of the library you are using. To get the version of the library you are using simply run:
43
44 $ strings android-armv7a-cl-asserts/libarm_compute.so | grep arm_compute_version
45 arm_compute_version=v16.12 Build options: {'embed_kernels': '1', 'opencl': '1', 'arch': 'armv7a', 'neon': '0', 'asserts': '1', 'debug': '0', 'os': 'android', 'Werror': '1'} Git hash=f51a545d4ea12a9059fe4e598a092f1fd06dc858
46
Anthony Barbier14c86a92017-12-14 16:27:41 +000047@section S0_2_prebuilt_binaries Pre-built binaries
48
49For each release we provide some pre-built binaries of the library [here](https://github.com/ARM-software/ComputeLibrary/releases)
50
51These binaries have been built using the following toolchains:
Isabella Gottardibe2de402018-11-21 15:23:49 +000052 - Linux armv7a: gcc-linaro-4.9-2016.02-x86_64_arm-linux-gnueabihf
Anthony Barbier14c86a92017-12-14 16:27:41 +000053 - Linux arm64-v8a: gcc-linaro-4.9-2016.02-x86_64_aarch64-linux-gnu
Anthony Barbierd51ea0a2018-08-07 17:48:03 +010054 - Android armv7a: clang++ / libc++ NDK r17b
55 - Android am64-v8a: clang++ / libc++ NDK r17b
Anthony Barbier14c86a92017-12-14 16:27:41 +000056
57@warning Make sure to use a compatible toolchain to build your application or you will get some std::bad_alloc errors at runtime.
58
Anthony Barbier6ff3b192017-09-04 18:44:23 +010059@section S1_file_organisation File organisation
60
61This archive contains:
62 - The arm_compute header and source files
63 - The latest Khronos OpenCL 1.2 C headers from the <a href="https://www.khronos.org/registry/cl/">Khronos OpenCL registry</a>
64 - The latest Khronos cl2.hpp from the <a href="https://www.khronos.org/registry/cl/">Khronos OpenCL registry</a> (API version 2.1 when this document was written)
Anthony Barbier20dbb822017-12-13 21:19:39 +000065 - The latest Khronos OpenGL ES 3.1 C headers from the <a href="https://www.khronos.org/registry/gles/">Khronos OpenGL ES registry</a>
66 - The latest Khronos EGL 1.5 C headers from the <a href="https://www.khronos.org/registry/gles/">Khronos EGL registry</a>
67 - The sources for a stub version of libOpenCL.so, libGLESv1_CM.so, libGLESv2.so and libEGL.so to help you build your application.
Anthony Barbier6ff3b192017-09-04 18:44:23 +010068 - An examples folder containing a few examples to compile and link against the library.
69 - A @ref utils folder containing headers with some boiler plate code used by the examples.
70 - This documentation.
71
72You should have the following file organisation:
73
74 .
75 ├── arm_compute --> All the arm_compute headers
Georgios Pinitasf112ede2019-03-01 19:11:20 +000076 │ ├── graph.h --> Includes all the Graph headers at once.
Anthony Barbier6ff3b192017-09-04 18:44:23 +010077 │   ├── core
78 │   │   ├── CL
Anthony Barbier6a5627a2017-09-26 14:42:02 +010079 │   │   │   ├── CLKernelLibrary.h --> Manages all the OpenCL kernels compilation and caching, provides accessors for the OpenCL Context.
Anthony Barbier6ff3b192017-09-04 18:44:23 +010080 │   │   │   ├── CLKernels.h --> Includes all the OpenCL kernels at once
81 │   │   │   ├── CL specialisation of all the generic objects interfaces (ICLTensor, ICLImage, etc.)
82 │   │   │   ├── kernels --> Folder containing all the OpenCL kernels
83 │   │   │   │   └── CL*Kernel.h
84 │   │   │   └── OpenCL.h --> Wrapper to configure the Khronos OpenCL C++ header
85 │   │ ├── CPP
Anthony Barbier6a5627a2017-09-26 14:42:02 +010086 │   │   │   ├── CPPKernels.h --> Includes all the CPP kernels at once
Anthony Barbier6ff3b192017-09-04 18:44:23 +010087 │   │ │   └── kernels --> Folder containing all the CPP kernels
Anthony Barbier6a5627a2017-09-26 14:42:02 +010088 │   │   │      └── CPP*Kernel.h
Anthony Barbier20dbb822017-12-13 21:19:39 +000089 │   │   ├── GLES_COMPUTE
90 │   │   │   ├── GCKernelLibrary.h --> Manages all the GLES kernels compilation and caching, provides accessors for the GLES Context.
91 │   │   │   ├── GCKernels.h --> Includes all the GLES kernels at once
92 │   │   │   ├── GLES specialisation of all the generic objects interfaces (IGCTensor, IGCImage, etc.)
93 │   │   │   ├── kernels --> Folder containing all the GLES kernels
94 │   │   │   │   └── GC*Kernel.h
95 │   │   │   └── OpenGLES.h --> Wrapper to configure the Khronos EGL and OpenGL ES C header
Anthony Barbier6ff3b192017-09-04 18:44:23 +010096 │   │   ├── NEON
97 │   │   │   ├── kernels --> Folder containing all the NEON kernels
Anthony Barbier38e7f1f2018-05-21 13:37:47 +010098 │   │   │   │ ├── assembly --> headers for assembly optimised NEON kernels.
99 │   │   │   │ ├── convolution --> headers for convolution assembly optimised NEON kernels.
100 │   │   │   │   │   ├── common --> headers for code which is common to several convolution implementations.
101 │   │   │   │   │   ├── depthwise --> headers for Depthwise convolultion assembly implementation
102 │   │   │   │   │   └── winograd --> headers for Winograd convolution assembly implementation
103 │   │   │   │ ├── detail --> Common code for several intrinsics implementations.
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100104 │   │   │   │   └── NE*Kernel.h
105 │   │   │   └── NEKernels.h --> Includes all the NEON kernels at once
106 │   │   ├── All common basic types (Types.h, Window, Coordinates, Iterator, etc.)
107 │   │   ├── All generic objects interfaces (ITensor, IImage, etc.)
108 │   │   └── Objects metadata classes (ImageInfo, TensorInfo, MultiImageInfo)
Anthony Barbier6a5627a2017-09-26 14:42:02 +0100109 │   ├── graph
Anthony Barbier38e7f1f2018-05-21 13:37:47 +0100110 │   │   ├── algorithms
111 │   │   │   └── Generic algorithms used by the graph backend (e.g Order of traversal)
112 │   │   ├── backends --> The backend specific code
113 │   │   │   ├── CL --> OpenCL specific operations
114 │   │   │   ├── GLES --> OpenGLES Compute Shaders specific operations
115 │   │   │   └── NEON --> NEON specific operations
116 │   │   ├── detail
117 │   │   │   └── Collection of internal utilities.
118 │   │   ├── frontend
119 │   │   │   └── Code related to the stream frontend interface.
120 │   │   ├── mutators
121 │   │   │   └── Used to modify / optimise the Graph intermediate representation(Operator fusion, in place operations, etc.)
Anthony Barbier6a5627a2017-09-26 14:42:02 +0100122 │   │   ├── nodes
123 │   │   │   └── The various nodes supported by the graph API
Anthony Barbier38e7f1f2018-05-21 13:37:47 +0100124 │   │   ├── printers
125 │   │   │   └── Debug printers
Anthony Barbier6a5627a2017-09-26 14:42:02 +0100126 │   │   └── Graph objects ( INode, ITensorAccessor, Graph, etc.)
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100127 │   └── runtime
128 │   ├── CL
129 │   │   ├── CL objects & allocators (CLArray, CLImage, CLTensor, etc.)
130 │   │   ├── functions --> Folder containing all the OpenCL functions
131 │   │   │   └── CL*.h
Anthony Barbier6a5627a2017-09-26 14:42:02 +0100132 │   │   ├── CLScheduler.h --> Interface to enqueue OpenCL kernels and get/set the OpenCL CommandQueue and ICLTuner.
Anthony Barbier38e7f1f2018-05-21 13:37:47 +0100133 │   │   ├── CLFunctions.h --> Includes all the OpenCL functions at once
134 │   │   └── tuners
135 │   │      └── Local workgroup size tuners for specific architectures / GPUs
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100136 │   ├── CPP
Anthony Barbier6a5627a2017-09-26 14:42:02 +0100137 │      │   ├── CPPKernels.h --> Includes all the CPP functions at once.
Anthony Barbier38e7f1f2018-05-21 13:37:47 +0100138 │   │   ├── CPPScheduler.h --> Basic pool of threads to execute CPP/NEON code on several cores in parallel
139 │   │   └── functions --> Folder containing all the CPP functions
140 │   │      └── CPP*.h
Anthony Barbier20dbb822017-12-13 21:19:39 +0000141 │   ├── GLES_COMPUTE
142 │   │   ├── GLES objects & allocators (GCArray, GCImage, GCTensor, etc.)
143 │   │   ├── functions --> Folder containing all the GLES functions
144 │   │   │   └── GC*.h
145 │   │   ├── GCScheduler.h --> Interface to enqueue GLES kernels and get/set the GLES CommandQueue.
146 │   │   └── GCFunctions.h --> Includes all the GLES functions at once
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100147 │   ├── NEON
148 │   │ ├── functions --> Folder containing all the NEON functions
149 │   │ │   └── NE*.h
150 │   │ └── NEFunctions.h --> Includes all the NEON functions at once
Anthony Barbier6a5627a2017-09-26 14:42:02 +0100151 │   ├── OMP
152 │   │   └── OMPScheduler.h --> OpenMP scheduler (Alternative to the CPPScheduler)
153 │ ├── Memory manager files (LifetimeManager, PoolManager, etc.)
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100154 │   └── Basic implementations of the generic object interfaces (Array, Image, Tensor, etc.)
Anthony Barbiera8a28f62018-02-26 19:16:32 +0000155 ├── data -> Contains test images and reference data dumps used by validation tests
156 ├── docs -> Contains Doxyfile and Doxygen sources used to generate the HTML pages in the documentation folder.
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100157 ├── documentation
158 │   ├── index.xhtml
159 │   └── ...
160 ├── documentation.xhtml -> documentation/index.xhtml
161 ├── examples
Anthony Barbier20dbb822017-12-13 21:19:39 +0000162 │   ├── cl_*.cpp --> OpenCL examples
Anthony Barbier14c86a92017-12-14 16:27:41 +0000163 │   ├── gc_*.cpp --> GLES compute shaders examples
Anthony Barbier20dbb822017-12-13 21:19:39 +0000164 │   ├── graph_*.cpp --> Graph examples
165 │   ├── neoncl_*.cpp --> NEON / OpenCL interoperability examples
166 │   └── neon_*.cpp --> NEON examples
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100167 ├── include
Anthony Barbier6a5627a2017-09-26 14:42:02 +0100168 │   ├── CL
169 │   │ └── Khronos OpenCL C headers and C++ wrapper
170 │   ├── half --> FP16 library available from http://half.sourceforge.net
Anthony Barbier14c86a92017-12-14 16:27:41 +0000171 │   ├── libnpy --> Library to load / write npy buffers, available from https://github.com/llohse/libnpy
172 │  └── linux --> Headers only needed for Linux builds
173 │   └── Khronos EGL and OpenGLES headers
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100174 ├── opencl-1.2-stubs
Anthony Barbier14c86a92017-12-14 16:27:41 +0000175 │ └── opencl_stubs.c --> OpenCL stubs implementation
176 ├── opengles-3.1-stubs
177 │   ├── EGL.c --> EGL stubs implementation
178 │   └── GLESv2.c --> GLESv2 stubs implementation
Anthony Barbier6a5627a2017-09-26 14:42:02 +0100179 ├── scripts
180 │   ├── caffe_data_extractor.py --> Basic script to export weights from Caffe to npy files
181 │   └── tensorflow_data_extractor.py --> Basic script to export weights from Tensor Flow to npy files
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100182 ├── src
183 │   ├── core
184 │ │ └── ... (Same structure as headers)
Anthony Barbier20dbb822017-12-13 21:19:39 +0000185 │   │ ├── CL
186 │   │ │ └── cl_kernels --> All the OpenCL kernels
187 │   │ └── GLES_COMPUTE
188 │   │ └── cs_shaders --> All the OpenGL ES Compute Shaders
Anthony Barbier6a5627a2017-09-26 14:42:02 +0100189 │   ├── graph
190 │ │ └── ... (Same structure as headers)
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100191 │ └── runtime
192 │ └── ... (Same structure as headers)
Anthony Barbier6a5627a2017-09-26 14:42:02 +0100193 ├── support
194 │ └── Various headers to work around toolchains / platform issues.
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100195 ├── tests
196 │   ├── All test related files shared between validation and benchmark
Anthony Barbier38e7f1f2018-05-21 13:37:47 +0100197 │   ├── benchmark --> Sources for benchmarking
198 │ │ ├── Benchmark specific files
199 │   │ ├── fixtures
200 │ │ │ └── Backend agnostic fixtures to initialise and run the functions to test.
201 │ │ ├── CL --> OpenCL benchmarking tests
202 │ │ ├── GLES_COMPUTE --> GLES benchmarking tests
203 │ │ └── NEON --> NEON benchmarking tests
Anthony Barbier6a5627a2017-09-26 14:42:02 +0100204 │   ├── CL --> OpenCL accessors
Anthony Barbier20dbb822017-12-13 21:19:39 +0000205 │   ├── GLES_COMPUTE --> GLES accessors
Anthony Barbier6a5627a2017-09-26 14:42:02 +0100206 │   ├── NEON --> NEON accessors
Anthony Barbier6a5627a2017-09-26 14:42:02 +0100207 │   ├── datasets
208 │ │ └── Datasets for all the validation / benchmark tests, layer configurations for various networks, etc.
209 │   ├── framework
210 │ │ └── Boiler plate code for both validation and benchmark test suites (Command line parsers, instruments, output loggers, etc.)
Anthony Barbier38e7f1f2018-05-21 13:37:47 +0100211 │   └── validation --> Sources for validation
212 │ ├── Validation specific files
213 │   ├── fixtures
214 │ │ └── Backend agnostic fixtures to initialise and run the functions to test.
215 │   ├── reference
216 │ │ └── Reference implementation used to validate the results of the various backends.
217 │ ├── CL --> OpenCL validation tests
218 │ ├── GLES_COMPUTE --> GLES validation tests
219 │ ├── CPP --> C++ reference implementations
220 │ └── NEON --> NEON validation tests
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100221 └── utils --> Boiler plate code used by examples
Anthony Barbier20dbb822017-12-13 21:19:39 +0000222 └── Various utilities to print types, load / store assets, etc.
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100223
224@section S2_versions_changelog Release versions and changelog
225
226@subsection S2_1_versions Release versions
227
228All releases are numbered vYY.MM Where YY are the last two digits of the year, and MM the month number.
229If there is more than one release in a month then an extra sequential number is appended at the end:
230
231 v17.03 (First release of March 2017)
232 v17.03.1 (Second release of March 2017)
233 v17.04 (First release of April 2017)
234
235@note We're aiming at releasing one major public release with new features per quarter. All releases in between will only contain bug fixes.
236
237@subsection S2_2_changelog Changelog
238
Georgios Pinitas3d13af82019-06-04 13:04:16 +0100239v19.08 Public major release
240 - Various bug fixes.
241 - Various optimisations.
Gian Marco Iodicebf193542019-08-22 10:10:52 +0100242 - Deprecated NEON functions
243 - NEDepthConcatenateLayer
244 - NEWidthConcatenateLayer
245 - Deprecated OpenCL kernels / functions
246 - CLDepthConcatenateLayer
247 - CLGEMMInterleave4x4Kernel / CLGEMMInterleave4x4
248 - CLGEMMTranspose1xWKernel / CLGEMMTranspose1xW
249 - CLWidthConcatenateLayer
250 - New NEON kernels / functions:
251 - @ref NECast
252 - @ref NELSTMLayerQuantized
253 - @ref NEPReluLayer
254 - @ref NEBatchConcatenateLayerKernel
255 - @ref NEDepthToSpaceLayerKernel / @ref NEDepthToSpaceLayer
256 - @ref NEDepthwiseConvolutionLayerNativeKernel
257 - @ref NEGEMMLowpQuantizeDownInt32ToInt16ScaleByFixedPointKernel
258 - @ref NEMeanStdDevNormalizationKernel / @ref NEMeanStdDevNormalizationLayer
259 - @ref NESpaceToDepthLayerKernel / @ref NESpaceToDepthLayer
260 - New OpenCL kernels / functions:
261 - @ref CLLSTMLayerQuantized
262 - @ref CLPReluLayer
263 - @ref CLBatchConcatenateLayerKernel
264 - @ref CLDepthToSpaceLayerKernel / @ref CLDepthToSpaceLayer
265 - @ref CLGEMMLowpMatrixMultiplyNativeKernel
266 - @ref CLGEMMLowpQuantizeDownInt32ToInt16ScaleByFixedPointKernel
267 - @ref CLGEMMMatrixMultiplyNativeKernel
268 - @ref CLMeanStdDevNormalizationKernel / @ref CLMeanStdDevNormalizationLayer
269 - @ref CLSpaceToDepthLayerKernel / @ref CLSpaceToDepthLayer
270 - New examples:
271 - neon_opticalflow
272 - cl_cache
273 - neon_permute
274 - Enable the fusion of batch normalization with convolution and depthwise convolution layer for FP32 in the graph API (OpenCL only)
275 - Added support for fusing activation function and broadcast addition with the matrix multiplication for FP32 (OpenCL only)
276 - Re-factored the depthwise convolution layer kernel on NEON for generic cases
277 - Added an optimized depthwise convolution layer kernel for 5x5 filters (NEON only)
278 - Added support to enable OpenCL kernel cache. Added example showing how to load the prebuilt OpenCL kernels from a binary cache file
279 - Altered @ref QuantizationInfo interface to support per-channel quantization.
280 - The @ref NEDepthwiseConvolutionLayer3x3 will be replaced by @ref NEDepthwiseConvolutionLayerOptimized to accommodate for future optimizations.
281 - Removed inner_border_right and inner_border_top parameters from @ref CLDeconvolutionLayer interface
282 - Removed inner_border_right and inner_border_top parameters from @ref NEDeconvolutionLayer interface
Georgios Pinitas3d13af82019-06-04 13:04:16 +0100283
Michalis Spyroua9c44722019-04-05 17:18:36 +0100284v19.05 Public major release
Michalis Spyrouc6608ac2019-05-16 17:40:23 +0100285 - Various bug fixes.
286 - Various optimisations.
Georgios Pinitasf790fdb2019-04-24 12:41:25 +0100287 - New Neon kernels / functions:
288 - @ref NEBatchToSpaceLayerKernel / @ref NEBatchToSpaceLayer
Michalis Spyrouca82e622019-05-10 16:43:20 +0100289 - @ref NEComplexPixelWiseMultiplicationKernel / @ref NEComplexPixelWiseMultiplication
Georgios Pinitasf790fdb2019-04-24 12:41:25 +0100290 - @ref NECropKernel / @ref NECropResize
Michalis Spyrouca82e622019-05-10 16:43:20 +0100291 - @ref NEDepthwiseConvolutionAssemblyDispatch
292 - @ref NEFFTDigitReverseKernel
293 - @ref NEFFTRadixStageKernel
294 - @ref NEFFTScaleKernel
Georgios Pinitasf790fdb2019-04-24 12:41:25 +0100295 - @ref NEGEMMLowpOffsetContributionOutputStageKernel
296 - @ref NEHeightConcatenateLayerKernel
297 - @ref NESpaceToBatchLayerKernel / @ref NESpaceToBatchLayer
Michalis Spyroud7dd15c2019-05-30 14:53:58 +0100298 - @ref NEFFT1D
299 - @ref NEFFT2D
300 - @ref NEFFTConvolutionLayer
Georgios Pinitasf790fdb2019-04-24 12:41:25 +0100301 - New OpenCL kernels / functions:
Michalis Spyrouca82e622019-05-10 16:43:20 +0100302 - @ref CLComplexPixelWiseMultiplicationKernel / @ref CLComplexPixelWiseMultiplication
Georgios Pinitasf790fdb2019-04-24 12:41:25 +0100303 - @ref CLCropKernel / @ref CLCropResize
Michalis Spyroud7dd15c2019-05-30 14:53:58 +0100304 - @ref CLDeconvolutionReshapeOutputKernel
Georgios Pinitasf790fdb2019-04-24 12:41:25 +0100305 - @ref CLFFTDigitReverseKernel
306 - @ref CLFFTRadixStageKernel
307 - @ref CLFFTScaleKernel
308 - @ref CLGEMMLowpMatrixMultiplyReshapedOnlyRHSKernel
309 - @ref CLGEMMMatrixMultiplyReshapedOnlyRHSKernel
310 - @ref CLHeightConcatenateLayerKernel
311 - @ref CLDirectDeconvolutionLayer
312 - @ref CLFFT1D
313 - @ref CLFFT2D
314 - @ref CLFFTConvolutionLayer
Michalis Spyrouca82e622019-05-10 16:43:20 +0100315 - @ref CLGEMMDeconvolutionLayer
316 - New OpenGLES kernels / functions:
317 - @ref GCConcatenateLayer
Michalis Spyroua9c44722019-04-05 17:18:36 +0100318 - Deprecated functions/interfaces
Georgios Pinitas09f24972019-05-17 18:14:40 +0100319 - GCDepthConcatenateLayer
320 - NEWidthConcatenateLayer
321 - NEDepthConcatenateLayer
322 - CLWidthConcatenateLayer
323 - CLDepthConcatenateLayer
Gian Marco Iodice5fc07aa2019-05-15 17:08:02 +0100324 - CLGEMMInterleave4x4
325 - CLGEMMTranspose1xW
Michalis Spyrouc6608ac2019-05-16 17:40:23 +0100326 - Support different quantization info in CLConcatLayer.
327 - Add checks on different input/output quantization info were not supported.
328 - Tensors have different quantization information.
329 - Add FP16 support checks.
330 - Fix output quantization CLDeptwiseConv3x3 when activation is fused.
331 - New graph examples:
332 - graph_convolution
333 - graph_fully_connected
334 - graph_depthwise_convolution
335 - Deepspeech v0.4.1
336 - Add support for QASYMM8 in NEArithmeticSubtractionKernel.
337 - Add support for QASYMM8 in NEPixelWiseMultiplicationKernel.
338 - Add support for QASYMM8 NEDeconvolution.
339 - Add support for DequantizationLayer for NEON/CL.
340 - Add support for dilation in CLDepthwiseConvolution.
341 - Fuse offset contribution with the output stage when we use NEGEMMLowpMatrixMultiplyCore.
342 - Optimize CLDeconvolution.
343 - Add StackLayer to the graph API.
344 - Add support for "reflect" padding mode in NEPad.
345 - Winograd 7x7 NHWC on OpenCL.
346 - Rework CL ML layers to run exclusively on CL.
347 - Support different quantization info in PoolingLayer.
348 - Implement and test import memory interfaces.
349 - Added new tests and removed old ones.
350 - Various clang-tidy fixes.
Michalis Spyroua9c44722019-04-05 17:18:36 +0100351
giuros01a69a88b2019-01-31 16:29:19 +0000352v19.02 Public major release
Isabella Gottardi62538972019-02-12 19:52:44 +0000353 - Various bug fixes.
354 - Various optimisations.
355 - New Neon kernels / functions:
356 - @ref NETileKernel / @ref NETile
357 - @ref NEFuseBatchNormalizationKernel / @ref NEFuseBatchNormalization
358 - @ref NEElementwiseOperationKernel
359 - @ref NEElementwiseMax
360 - @ref NEElementwiseMin
361 - @ref NEElementwiseSquaredDiff
362 - @ref NESelectKernel / @ref NESelect
363 - @ref NESplit
364 - @ref NESlice
365 - @ref NEUnstack
366 - @ref NEStridedSliceKernel / @ref NEStridedSlice
367 - @ref NEElementwiseUnaryKernel
368 - @ref NERsqrtLayer
369 - @ref NEExpLayer
370 - @ref NEReverseKernel / @ref NEReverse
371 - @ref NEArgMinMaxLayer
372 - @ref NEStackLayerKernel / @ref NEStackLayer
373 - @ref NERangeKernel / @ref NERange
374 - @ref NEPadLayer
375 - @ref NEMemsetKernel
376 - @ref NEGatherKernel / @ref NEGather
377 - @ref NEElementwiseComparison
378 - @ref NEElementwiseComparisonStatic
379 - @ref NEComparisonOperationKernel
380 - @ref NEElementwiseDivision
381 - New OpenCL kernels / functions:
382 - @ref CLSelectKernel / @ref CLSelect
383 - @ref CLTileKernel / @ref CLTile
384 - @ref CLComparisonKernel / @ref CLComparison
385 - @ref CLArgMinMaxLayer
386 - @ref CLElementwiseMax
387 - @ref CLElementwiseMin
388 - @ref CLElementwiseSquaredDiff
389 - @ref CLStackLayerKernel / @ref CLStackLayer
390 - @ref CLReverse / @ref CLReverseKernel
391 - @ref CLRsqrtLayer
392 - @ref CLExpLayer
393 - @ref CLElementWiseUnaryLayerKernel
394 - @ref CLGEMMReshapeLHSMatrixKernel
395 - @ref CLGEMMReshapeRHSMatrixKernel
396 - @ref CLGEMMMatrixMultiplyReshapedKernel
397 - @ref CLRangeKernel / @ref CLRange
398 - @ref CLUnstack
399 - @ref CLGatherKernel / @ref CLGather
400 - @ref CLGEMMLowpMatrixMultiplyReshapedKernel
401 - New CPP kernels / functions:
402 - @ref CPPDetectionOutputLayer
403 - @ref CPPTopKV / @ref CPPTopKVKernel
Isabella Gottardi62538972019-02-12 19:52:44 +0000404 - Added new examples:
405 - graph_ssd_mobilenet.cpp
406 - graph_mobilenet_v2.cpp
407 - graph_resnet12.cpp
408 - graph_srcnn955.cpp
409 - graph_vgg_vdsr.cpp
410 - graph_inception_resnet_v1.cpp
411 - Add 4D tensors support to
412 - @ref NESoftmaxLayer
413 - Fused activation in @ref CLWinogradConvolutionLayer
414 - Extented @ref NEPermute to support more cases
415 - Added NEON/SVE GEMM Hybrid kernels
416 - Added u8 and s8 hybrid assembly kernels
417 - Introduced GEMM strategy name in NEGEMMAssemblyWrapper
418 - Improved @ref CLTuner
419 - Fused the bias addition within @ref CLGEMM
420 - Added support for QASYMM8 LOGISTIC activation in @ref NEActivationLayer
421 - Added NHWC data layout support to:
422 - @ref NEScale for F16
423 - @ref CLNormalizationLayer IN_MAP_2D for FP32/FP16
424 - @ref NEL2NormalizeLayer for FP32/FP16
425 - @ref NENormalizationLayer IN_MAP_2D for FP32/FP16
426 - @ref CLROIAlignLayer
Manuel Bottini5209be52019-02-13 16:34:56 +0000427 - @ref CLGenerateProposalsLayer
Isabella Gottardi62538972019-02-12 19:52:44 +0000428 - Added QASYMM8 support to the following kernels:
429 - @ref NEArithmeticAdditionKernel
430 - @ref NEScale
431 - Added new tests and improved validation and benchmarking suites.
giuros01a69a88b2019-01-31 16:29:19 +0000432 - Deprecated functions/interfaces
433 - Usage of inner_border_right and inner_border_top has been deprecated in @ref CLDeconvolutionLayer and @ref NEDeconvolutionLayer
434
Isabella Gottardi8773d7c2018-11-20 09:56:46 +0000435v18.11 Public major release
436 - Various bug fixes.
437 - Various optimisations.
438 - New Neon kernels / functions:
439 - @ref NEChannelShuffleLayer / @ref NEChannelShuffleLayerKernel
440 - @ref NEReduceMean
441 - @ref NEReorgLayer / @ref NEReorgLayerKernel
442 - @ref NEPriorBoxLayer / @ref NEPriorBoxLayerKernel
443 - @ref NEUpsampleLayer / @ref NEUpsampleLayerKernel
444 - @ref NEYOLOLayer / @ref NEYOLOLayerKernel
445 - New OpenCL kernels / functions:
446 - @ref CLBatchToSpaceLayer / @ref CLBatchToSpaceLayerKernel
447 - @ref CLBoundingBoxTransform / @ref CLBoundingBoxTransformKernel
Manuel Bottini5209be52019-02-13 16:34:56 +0000448 - @ref CLComputeAllAnchorsKernel
449 - @ref CLGenerateProposalsLayer
Isabella Gottardi8773d7c2018-11-20 09:56:46 +0000450 - @ref CLNormalizePlanarYUVLayer / @ref CLNormalizePlanarYUVLayerKernel
451 - @ref CLReorgLayer / @ref CLReorgLayerKernel
452 - @ref CLSpaceToBatchLayer / @ref CLSpaceToBatchLayerKernel
453 - @ref CLPadLayer
454 - @ref CLReduceMean
455 - @ref CLPriorBoxLayer / @ref CLPriorBoxLayerKernel
456 - @ref CLROIAlignLayer / @ref CLROIAlignLayerKernel
457 - @ref CLSlice
458 - @ref CLSplit
459 - @ref CLStridedSlice / @ref CLStridedSliceKernel
460 - @ref CLUpsampleLayer / @ref CLUpsampleLayerKernel
461 - @ref CLYOLOLayer / @ref CLYOLOLayerKernel
462 - New CPP kernels / functions:
463 - @ref CPPBoxWithNonMaximaSuppressionLimit / @ref CPPBoxWithNonMaximaSuppressionLimitKernel
464 - Added the validate method in:
465 - @ref NEDepthConvertLayer
466 - @ref NEFloor / @ref CLFloor
467 - @ref NEGEMMMatrixAdditionKernel
468 - @ref NEReshapeLayer / @ref CLReshapeLayer
469 - @ref CLScale
470 - Added new examples:
471 - graph_shufflenet.cpp
472 - graph_yolov3.cpp
473 - Added documentation for add a new function or kernel.
474 - Improved doxygen documentation adding a list of the existing functions.
475 - Add 4D tensors support to
Georgios Pinitas09f24972019-05-17 18:14:40 +0100476 - CLWidthConcatenateLayer
Isabella Gottardi8773d7c2018-11-20 09:56:46 +0000477 - @ref CLFlattenLayer
478 - @ref CLSoftmaxLayer
479 - Add dot product support for @ref CLDepthwiseConvolutionLayer3x3NHWCKernel non-unit stride
480 - Add SVE support
481 - Fused batch normalization into convolution layer weights in @ref CLFuseBatchNormalization
482 - Fuses activation in @ref CLDepthwiseConvolutionLayer3x3NCHWKernel, @ref CLDepthwiseConvolutionLayer3x3NHWCKernel and @ref NEGEMMConvolutionLayer
483 - Added NHWC data layout support to:
484 - @ref CLChannelShuffleLayer
485 - @ref CLDeconvolutionLayer
486 - @ref CLL2NormalizeLayer
487 - Added QASYMM8 support to the following kernels:
488 - @ref CLScaleKernel
489 - @ref NEDepthwiseConvolutionLayer3x3Kernel
490 - @ref CLPixelWiseMultiplicationKernel
491 - Added FP16 support to the following kernels:
492 - @ref CLDepthwiseConvolutionLayer3x3NHWCKernel
493 - @ref NEDepthwiseConvolutionLayer3x3Kernel
494 - @ref CLNormalizePlanarYUVLayerKernel
495 - @ref CLWinogradConvolutionLayer (5x5 kernel)
496 - More tests added to both validation and benchmarking suites.
497
Anthony Barbierd51ea0a2018-08-07 17:48:03 +0100498v18.08 Public major release
499 - Various bug fixes.
Michele Di Giorgio02baf012018-08-20 18:10:38 +0100500 - Various optimisations.
Anthony Barbierd51ea0a2018-08-07 17:48:03 +0100501 - Updated recommended NDK version to r17b.
Michele Di Giorgio02baf012018-08-20 18:10:38 +0100502 - Removed support for QS8/QS16 data types.
503 - Added support for grouped convolution in @ref CLConvolutionLayer.
504 - Added NHWC data layout support to:
Georgios Pinitas09f24972019-05-17 18:14:40 +0100505 - NEDepthConcatenateLayer / CLDepthConcatenateLayer
Michele Di Giorgio02baf012018-08-20 18:10:38 +0100506 - @ref NEWinogradConvolutionLayer / @ref CLWinogradConvolutionLayer
507 - @ref CLDepthwiseConvolutionLayer
508 - @ref CLDirectConvolutionLayer
509 - @ref CLConvolutionLayer
510 - @ref CLScale
511 - @ref CLIm2ColKernel
512 - New Neon kernels / functions:
513 - @ref NERNNLayer
514 - New OpenCL kernels / functions:
515 - @ref CLArithmeticDivision
516 - Introduced prepare() stage support in the graph API for GLES.
517 - Added support for memory reusage when trying to allocate smaller CLTensors.
518 - Enabled NHWC execution on graph examples.
519 - Added JPEG accessor for validation purposes.
520 - Added validate methods to some kernels / functions.
Anthony Barbierd51ea0a2018-08-07 17:48:03 +0100521
522v18.05 Public major release
Pablo Tellob5cc95b2018-05-15 11:49:33 +0100523 - Various bug fixes.
524 - Various optimisations.
Pablo Telloeb82fd22018-02-23 13:43:50 +0000525 - Major redesign in the interface for the neon kernels implemented in assembly.
526 - Removed arm_compute::NEGEMMLowpAArch64A53Kernel / arm_compute::NEGEMMLowpAArch64Kernel / arm_compute::NEGEMMLowpAArch64V8P4Kernel / arm_compute::NEGEMMInterleavedBlockedKernel / arm_compute::NEGEMMLowpAssemblyMatrixMultiplyCore / arm_compute::NEHGEMMAArch64FP16Kernel
527 - Added NEGEMMAssemblyWrapper and AssemblyKernelGlue which are used to execute assembly kernels in neon functions.
528 - Minor changes to the CPUInfo type to make it compatible with the new assembly gemm interface.
Pablo Tellob5cc95b2018-05-15 11:49:33 +0100529 - Moved neon assembly kernels to the folder src/core/NEON/kernels/arm_gemm.
530 - Improved doxygen documentation.
531 - Improved memory management for layer's transitions.
532 - Added support for NHWC data layout in tensors.
533 - Added NHWC data layout support to:
534 - @ref NEGEMMConvolutionLayer
535 - @ref NEDirectConvolutionLayer
536 - @ref NEPoolingLayer / @ref CLPoolingLayer
537 - @ref NEBatchNormalizationLayer / @ref CLBatchNormalizationLayer
538 - @ref NEDepthwiseConvolutionLayer
539 - @ref NEScale
540 - @ref NEIm2Col
541 - Added support for dilated convolutions in @ref NEConvolutionLayer and @ref CLConvolutionLayer.
542 - New OpenCL kernels / functions:
543 - @ref CLChannelShuffleLayer / @ref CLChannelShuffleLayerKernel
544 - @ref CLConvertFullyConnectedWeightsKernel / @ref CLConvertFullyConnectedWeights
545 - @ref CLCopy / @ref CLCopyKernel
Anthony Barbier38e7f1f2018-05-21 13:37:47 +0100546 - @ref CLLSTMLayer
Pablo Tellob5cc95b2018-05-15 11:49:33 +0100547 - @ref CLRNNLayer
Georgios Pinitas09f24972019-05-17 18:14:40 +0100548 - CLWidthConcatenateLayer / @ref CLWidthConcatenateLayerKernel
Pablo Tellob5cc95b2018-05-15 11:49:33 +0100549 - @ref CLWinogradFilterTransformKernel / @ref CLWinogradInputTransformKernel / @ref CLWinogradConvolutionLayer
550 - @ref CLWinogradInputTransformKernel / @ref CLWinogradInputTransform
551 - New Neon kernels / functions:
Pablo Tellob5cc95b2018-05-15 11:49:33 +0100552 - @ref NEConvertFullyConnectedWeightsKernel / @ref NEConvertFullyConnectedWeights.
553 - Created the validate method in @ref CLDepthwiseConvolutionLayer.
554 - Beta and gamma are no longer mandatory arguments in @ref NEBatchNormalizationLayer and @ref CLBatchNormalizationLayer.
555 - Added depth multiplier support in @ref NEDepthwiseConvolutionLayer and @ref CLDepthwiseConvolutionLayer.
556 - Added broadcast multiply support in @ref NEPixelWiseMultiplication / @ref NEPixelWiseMultiplicationKernel.
557 - Port mobilenet example to NHWC data layout.
558 - Enabled Winograd method in @ref CLConvolutionLayer.
559 - Renamed NEWinogradLayer to @ref NEWinogradConvolutionLayer.
560 - Updated @ref NEWinogradConvolutionLayer to use highly optimised assembly kernels in src/core/NEON/kernels/arm_gemm.
561 - Added memory manager support in GLES functions.
562 - Major refactoring of the graph API.
563 - Added GLES backend in the graph API.
564 - Added support for the memory manager in the graph API.
565 - Enabled Winograd Convolution method in the graph API.
566 - Added support for grouped convolutions in the graph API.
567 - Replaced NEDeconvolutionLayerUpsampleKernel with @ref NEScaleKernel in @ref NEDeconvolutionLayer.
568 - Added fast maths flag in @ref CLConvolutionLayer.
569 - Added new tests and benchmarks in validation and benchmark frameworks
570 - Merge Activation layer with Convolution Layer (NEON. CL, GLES)
571 - Added support to OpenCL 2.0 SVM
572 - Added support to import memory in OpenCL tensors.
573 - Added the prepare() method to perform any one off pre-processing before running the function.
574 - Added new examples:
575 - graph_inception_v4.cpp
Anthony Barbier38e7f1f2018-05-21 13:37:47 +0100576 - graph_resnext50.cpp
Pablo Tellob5cc95b2018-05-15 11:49:33 +0100577 - Added memory measurement instrument for CL.
Pablo Telloeb82fd22018-02-23 13:43:50 +0000578
Anthony Barbier577fbdf2018-03-01 15:17:54 +0000579v18.03 Public maintenance release
580 - Various bug fixes.
Anthony Barbier3762e742018-03-02 11:49:33 +0000581 - Fixed bug in @ref NEActivationLayer
582 - Fix in @ref CLTuner when using batches.
Anthony Barbier577fbdf2018-03-01 15:17:54 +0000583 - Updated recommended NDK version to r16b (And fixed warnings).
584 - Fixed bug in validation code.
585 - Added Inception v4 graph example.
Georgios Pinitas9fb11592018-04-26 20:34:58 +0100586 - Renamed NEWinogradLayer.cpp to @ref NEWinogradConvolutionLayer
Anthony Barbier577fbdf2018-03-01 15:17:54 +0000587
Anthony Barbier2d0ce772018-02-21 15:35:36 +0000588v18.02 Public major release
589 - Various NEON / OpenCL / GLES optimisations.
590 - Various bug fixes.
591 - Changed default number of threads on big LITTLE systems.
592 - Refactored examples and added:
593 - graph_mobilenet_qassym8
594 - graph_resnet
595 - graph_squeezenet_v1_1
Anthony Barbier3762e742018-03-02 11:49:33 +0000596 - Renamed @ref CLConvolutionLayer into @ref CLGEMMConvolutionLayer and created a new @ref CLConvolutionLayer to select the fastest convolution method.
597 - Renamed @ref NEConvolutionLayer into @ref NEGEMMConvolutionLayer and created a new @ref NEConvolutionLayer to select the fastest convolution method.
Anthony Barbier2d0ce772018-02-21 15:35:36 +0000598 - Added in place support to:
Anthony Barbier3762e742018-03-02 11:49:33 +0000599 - @ref CLActivationLayer
600 - @ref CLBatchNormalizationLayer
Anthony Barbier2d0ce772018-02-21 15:35:36 +0000601 - Added QASYMM8 support to:
Anthony Barbier3762e742018-03-02 11:49:33 +0000602 - @ref CLActivationLayer
603 - @ref CLDepthwiseConvolutionLayer
604 - @ref NEDepthwiseConvolutionLayer
605 - @ref NESoftmaxLayer
Anthony Barbier2d0ce772018-02-21 15:35:36 +0000606 - Added FP16 support to:
Anthony Barbier3762e742018-03-02 11:49:33 +0000607 - @ref CLDepthwiseConvolutionLayer3x3
608 - @ref CLDepthwiseConvolutionLayer
609 - Added broadcasting support to @ref NEArithmeticAddition / @ref CLArithmeticAddition / @ref CLPixelWiseMultiplication
610 - Added fused batched normalization and activation to @ref CLBatchNormalizationLayer and @ref NEBatchNormalizationLayer
611 - Added support for non-square pooling to @ref NEPoolingLayer and @ref CLPoolingLayer
Anthony Barbier2d0ce772018-02-21 15:35:36 +0000612 - New OpenCL kernels / functions:
Anthony Barbier3762e742018-03-02 11:49:33 +0000613 - @ref CLDirectConvolutionLayerOutputStageKernel
Pablo Tellof6c572c2018-02-14 12:47:30 +0000614 - New NEON kernels / functions
Anthony Barbier2d0ce772018-02-21 15:35:36 +0000615 - Added name() method to all kernels.
616 - Added support for Winograd 5x5.
Anthony Barbier3762e742018-03-02 11:49:33 +0000617 - @ref NEPermuteKernel / @ref NEPermute
Georgios Pinitas9fb11592018-04-26 20:34:58 +0100618 - @ref NEWinogradLayerTransformInputKernel / NEWinogradLayer
619 - @ref NEWinogradLayerTransformOutputKernel / NEWinogradLayer
620 - @ref NEWinogradLayerTransformWeightsKernel / NEWinogradLayer
Anthony Barbiere1553372018-07-16 18:53:52 +0100621 - Renamed NEWinogradLayerKernel into NEWinogradLayerBatchedGEMMKernel
Anthony Barbier2d0ce772018-02-21 15:35:36 +0000622 - New GLES kernels / functions:
Anthony Barbier3762e742018-03-02 11:49:33 +0000623 - @ref GCTensorShiftKernel / @ref GCTensorShift
Pablo Tellof6c572c2018-02-14 12:47:30 +0000624
Anthony Barbier64c95a02018-01-22 18:48:55 +0000625v18.01 Public maintenance release
626 - Various bug fixes
627 - Added some of the missing validate() methods
Anthony Barbier3762e742018-03-02 11:49:33 +0000628 - Added @ref CLDeconvolutionLayerUpsampleKernel / @ref CLDeconvolutionLayer @ref CLDeconvolutionLayerUpsample
629 - Added @ref CLPermuteKernel / @ref CLPermute
Anthony Barbier64c95a02018-01-22 18:48:55 +0000630 - Added method to clean the programs cache in the CL Kernel library.
Anthony Barbier3762e742018-03-02 11:49:33 +0000631 - Added @ref GCArithmeticAdditionKernel / @ref GCArithmeticAddition
632 - Added @ref GCDepthwiseConvolutionLayer3x3Kernel / @ref GCDepthwiseConvolutionLayer3x3
633 - Added @ref GCNormalizePlanarYUVLayerKernel / @ref GCNormalizePlanarYUVLayer
634 - Added @ref GCScaleKernel / @ref GCScale
635 - Added @ref GCWeightsReshapeKernel / @ref GCConvolutionLayer
Anthony Barbier64c95a02018-01-22 18:48:55 +0000636 - Added FP16 support to the following GLES compute kernels:
Anthony Barbier3762e742018-03-02 11:49:33 +0000637 - @ref GCCol2ImKernel
638 - @ref GCGEMMInterleave4x4Kernel
639 - @ref GCGEMMTranspose1xWKernel
640 - @ref GCIm2ColKernel
641 - Refactored NEON Winograd (NEWinogradLayerKernel)
642 - Added @ref NEDirectConvolutionLayerOutputStageKernel
Anthony Barbier64c95a02018-01-22 18:48:55 +0000643 - Added QASYMM8 support to the following NEON kernels:
Anthony Barbier3762e742018-03-02 11:49:33 +0000644 - @ref NEDepthwiseConvolutionLayer3x3Kernel
645 - @ref NEFillBorderKernel
646 - @ref NEPoolingLayerKernel
Anthony Barbier64c95a02018-01-22 18:48:55 +0000647 - Added new examples:
648 - graph_cl_mobilenet_qasymm8.cpp
649 - graph_inception_v3.cpp
650 - gc_dc.cpp
651 - More tests added to both validation and benchmarking suites.
652
Gian Marcoff850932017-12-11 12:37:17 +0000653v17.12 Public major release
654 - Most machine learning functions on OpenCL support the new data type QASYMM8
655 - Introduced logging interface
656 - Introduced opencl timer
657 - Reworked GEMMLowp interface
658 - Added new NEON assembly kernels for GEMMLowp, SGEMM and HGEMM
659 - Added validation method for most Machine Learning kernels / functions
660 - Added new graph examples such as googlenet, mobilenet, squeezenet, vgg16 and vgg19
661 - Added sgemm example for OpenCL
662 - Added absolute difference example for GLES compute
663 - Added new tests and benchmarks in validation and benchmark frameworks
664 - Added new kernels / functions for GLES compute
665
666 - New OpenGL ES kernels / functions
Anthony Barbier3762e742018-03-02 11:49:33 +0000667 - @ref GCAbsoluteDifferenceKernel / @ref GCAbsoluteDifference
668 - @ref GCActivationLayerKernel / @ref GCActivationLayer
669 - @ref GCBatchNormalizationLayerKernel / @ref GCBatchNormalizationLayer
670 - @ref GCCol2ImKernel
Georgios Pinitas09f24972019-05-17 18:14:40 +0100671 - @ref GCDepthConcatenateLayerKernel / GCDepthConcatenateLayer
Anthony Barbier3762e742018-03-02 11:49:33 +0000672 - @ref GCDirectConvolutionLayerKernel / @ref GCDirectConvolutionLayer
673 - @ref GCDropoutLayerKernel / @ref GCDropoutLayer
674 - @ref GCFillBorderKernel / @ref GCFillBorder
675 - @ref GCGEMMInterleave4x4Kernel / @ref GCGEMMInterleave4x4
676 - @ref GCGEMMMatrixAccumulateBiasesKernel / @ref GCGEMMMatrixAdditionKernel / @ref GCGEMMMatrixMultiplyKernel / @ref GCGEMM
677 - @ref GCGEMMTranspose1xWKernel / @ref GCGEMMTranspose1xW
678 - @ref GCIm2ColKernel
679 - @ref GCNormalizationLayerKernel / @ref GCNormalizationLayer
680 - @ref GCPixelWiseMultiplicationKernel / @ref GCPixelWiseMultiplication
681 - @ref GCPoolingLayerKernel / @ref GCPoolingLayer
682 - @ref GCLogits1DMaxKernel / @ref GCLogits1DShiftExpSumKernel / @ref GCLogits1DNormKernel / @ref GCSoftmaxLayer
683 - @ref GCTransposeKernel / @ref GCTranspose
Gian Marcoff850932017-12-11 12:37:17 +0000684
685 - New NEON kernels / functions
Pablo Telloeb82fd22018-02-23 13:43:50 +0000686 - arm_compute::NEGEMMLowpAArch64A53Kernel / arm_compute::NEGEMMLowpAArch64Kernel / arm_compute::NEGEMMLowpAArch64V8P4Kernel / arm_compute::NEGEMMInterleavedBlockedKernel / arm_compute::NEGEMMLowpAssemblyMatrixMultiplyCore
687 - arm_compute::NEHGEMMAArch64FP16Kernel
Anthony Barbier3762e742018-03-02 11:49:33 +0000688 - @ref NEDepthwiseConvolutionLayer3x3Kernel / @ref NEDepthwiseIm2ColKernel / @ref NEGEMMMatrixVectorMultiplyKernel / @ref NEDepthwiseVectorToTensorKernel / @ref NEDepthwiseConvolutionLayer
689 - @ref NEGEMMLowpOffsetContributionKernel / @ref NEGEMMLowpMatrixAReductionKernel / @ref NEGEMMLowpMatrixBReductionKernel / @ref NEGEMMLowpMatrixMultiplyCore
690 - @ref NEGEMMLowpQuantizeDownInt32ToUint8ScaleByFixedPointKernel / @ref NEGEMMLowpQuantizeDownInt32ToUint8ScaleByFixedPoint
691 - @ref NEGEMMLowpQuantizeDownInt32ToUint8ScaleKernel / @ref NEGEMMLowpQuantizeDownInt32ToUint8Scale
Georgios Pinitas9fb11592018-04-26 20:34:58 +0100692 - NEWinogradLayer / NEWinogradLayerKernel
Gian Marcoff850932017-12-11 12:37:17 +0000693
694 - New OpenCL kernels / functions
Anthony Barbier3762e742018-03-02 11:49:33 +0000695 - @ref CLGEMMLowpOffsetContributionKernel / @ref CLGEMMLowpMatrixAReductionKernel / @ref CLGEMMLowpMatrixBReductionKernel / @ref CLGEMMLowpMatrixMultiplyCore
696 - @ref CLGEMMLowpQuantizeDownInt32ToUint8ScaleByFixedPointKernel / @ref CLGEMMLowpQuantizeDownInt32ToUint8ScaleByFixedPoint
697 - @ref CLGEMMLowpQuantizeDownInt32ToUint8ScaleKernel / @ref CLGEMMLowpQuantizeDownInt32ToUint8Scale
Gian Marcoff850932017-12-11 12:37:17 +0000698
699 - New graph nodes for NEON and OpenCL
Georgios Pinitasd9eb2752018-04-03 13:44:29 +0100700 - graph::BranchLayer
701 - graph::DepthConvertLayer
702 - graph::DepthwiseConvolutionLayer
703 - graph::DequantizationLayer
704 - graph::FlattenLayer
705 - graph::QuantizationLayer
706 - graph::ReshapeLayer
Gian Marcoff850932017-12-11 12:37:17 +0000707
Anthony Barbier3c5b4ff2017-10-12 13:20:52 +0100708v17.10 Public maintenance release
709 - Bug fixes:
710 - Check the maximum local workgroup size supported by OpenCL devices
711 - Minor documentation updates (Fixed instructions to build the examples)
Anthony Barbier3762e742018-03-02 11:49:33 +0000712 - Introduced a graph::GraphContext
Anthony Barbier3c5b4ff2017-10-12 13:20:52 +0100713 - Added a few new Graph nodes, support for branches and grouping.
714 - Automatically enable cl_printf in debug builds
715 - Fixed bare metal builds for armv7a
716 - Added AlexNet and cartoon effect examples
717 - Fixed library builds: libraries are no longer built as supersets of each other.(It means application using the Runtime part of the library now need to link against both libarm_compute_core and libarm_compute)
718
Anthony Barbier6a5627a2017-09-26 14:42:02 +0100719v17.09 Public major release
720 - Experimental Graph support: initial implementation of a simple stream API to easily chain machine learning layers.
Anthony Barbier3762e742018-03-02 11:49:33 +0000721 - Memory Manager (@ref BlobLifetimeManager, @ref BlobMemoryPool, @ref ILifetimeManager, @ref IMemoryGroup, @ref IMemoryManager, @ref IMemoryPool, @ref IPoolManager, @ref MemoryManagerOnDemand, @ref PoolManager)
Anthony Barbier6a5627a2017-09-26 14:42:02 +0100722 - New validation and benchmark frameworks (Boost and Google frameworks replaced by homemade framework).
723 - Most machine learning functions support both fixed point 8 and 16 bit (QS8, QS16) for both NEON and OpenCL.
724 - New NEON kernels / functions:
Pablo Telloeb82fd22018-02-23 13:43:50 +0000725 - arm_compute::NEGEMMAssemblyBaseKernel arm_compute::NEGEMMAArch64Kernel
Anthony Barbier3762e742018-03-02 11:49:33 +0000726 - @ref NEDequantizationLayerKernel / @ref NEDequantizationLayer
727 - @ref NEFloorKernel / @ref NEFloor
728 - @ref NEL2NormalizeLayerKernel / @ref NEL2NormalizeLayer
729 - @ref NEQuantizationLayerKernel @ref NEMinMaxLayerKernel / @ref NEQuantizationLayer
730 - @ref NEROIPoolingLayerKernel / @ref NEROIPoolingLayer
731 - @ref NEReductionOperationKernel / @ref NEReductionOperation
732 - @ref NEReshapeLayerKernel / @ref NEReshapeLayer
Anthony Barbier6a5627a2017-09-26 14:42:02 +0100733
734 - New OpenCL kernels / functions:
giuros016d109962019-01-07 17:47:19 +0000735 - @ref CLDepthwiseConvolutionLayer3x3NCHWKernel @ref CLDepthwiseConvolutionLayer3x3NHWCKernel @ref CLDepthwiseIm2ColKernel @ref CLDepthwiseVectorToTensorKernel CLDepthwiseWeightsReshapeKernel / @ref CLDepthwiseConvolutionLayer3x3 @ref CLDepthwiseConvolutionLayer @ref CLDepthwiseSeparableConvolutionLayer
Anthony Barbier3762e742018-03-02 11:49:33 +0000736 - @ref CLDequantizationLayerKernel / @ref CLDequantizationLayer
737 - @ref CLDirectConvolutionLayerKernel / @ref CLDirectConvolutionLayer
738 - @ref CLFlattenLayer
739 - @ref CLFloorKernel / @ref CLFloor
Gian Marco Iodice5fc07aa2019-05-15 17:08:02 +0100740 - CLGEMMTranspose1xW
Anthony Barbier3762e742018-03-02 11:49:33 +0000741 - @ref CLGEMMMatrixVectorMultiplyKernel
742 - @ref CLL2NormalizeLayerKernel / @ref CLL2NormalizeLayer
743 - @ref CLQuantizationLayerKernel @ref CLMinMaxLayerKernel / @ref CLQuantizationLayer
744 - @ref CLROIPoolingLayerKernel / @ref CLROIPoolingLayer
745 - @ref CLReductionOperationKernel / @ref CLReductionOperation
746 - @ref CLReshapeLayerKernel / @ref CLReshapeLayer
Anthony Barbier6a5627a2017-09-26 14:42:02 +0100747
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100748v17.06 Public major release
749 - Various bug fixes
750 - Added support for fixed point 8 bit (QS8) to the various NEON machine learning kernels.
751 - Added unit tests and benchmarks (AlexNet, LeNet)
752 - Added support for sub tensors.
753 - Added infrastructure to provide GPU specific optimisation for some OpenCL kernels.
Anthony Barbier3762e742018-03-02 11:49:33 +0000754 - Added @ref OMPScheduler (OpenMP) scheduler for NEON
755 - Added @ref SingleThreadScheduler scheduler for NEON (For bare metal)
756 - User can specify his own scheduler by implementing the @ref IScheduler interface.
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100757 - New OpenCL kernels / functions:
Anthony Barbier3762e742018-03-02 11:49:33 +0000758 - @ref CLBatchNormalizationLayerKernel / @ref CLBatchNormalizationLayer
Georgios Pinitas09f24972019-05-17 18:14:40 +0100759 - @ref CLDepthConcatenateLayerKernel / CLDepthConcatenateLayer
Anthony Barbier3762e742018-03-02 11:49:33 +0000760 - @ref CLHOGOrientationBinningKernel @ref CLHOGBlockNormalizationKernel, @ref CLHOGDetectorKernel / @ref CLHOGDescriptor @ref CLHOGDetector @ref CLHOGGradient @ref CLHOGMultiDetection
761 - @ref CLLocallyConnectedMatrixMultiplyKernel / @ref CLLocallyConnectedLayer
762 - @ref CLWeightsReshapeKernel / @ref CLConvolutionLayerReshapeWeights
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100763 - New C++ kernels:
Anthony Barbier3762e742018-03-02 11:49:33 +0000764 - @ref CPPDetectionWindowNonMaximaSuppressionKernel
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100765 - New NEON kernels / functions:
Anthony Barbier3762e742018-03-02 11:49:33 +0000766 - @ref NEBatchNormalizationLayerKernel / @ref NEBatchNormalizationLayer
Georgios Pinitas09f24972019-05-17 18:14:40 +0100767 - @ref NEDepthConcatenateLayerKernel / NEDepthConcatenateLayer
Anthony Barbier3762e742018-03-02 11:49:33 +0000768 - @ref NEDirectConvolutionLayerKernel / @ref NEDirectConvolutionLayer
769 - @ref NELocallyConnectedMatrixMultiplyKernel / @ref NELocallyConnectedLayer
770 - @ref NEWeightsReshapeKernel / @ref NEConvolutionLayerReshapeWeights
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100771
772v17.05 Public bug fixes release
773 - Various bug fixes
774 - Remaining of the functions ported to use accurate padding.
775 - Library does not link against OpenCL anymore (It uses dlopen / dlsym at runtime instead to determine whether or not OpenCL is available).
776 - Added "free" method to allocator.
777 - Minimum version of g++ required for armv7 Linux changed from 4.8 to 4.9
778
779v17.04 Public bug fixes release
780
781 The following functions have been ported to use the new accurate padding:
Anthony Barbier3762e742018-03-02 11:49:33 +0000782 - @ref CLColorConvertKernel
783 - @ref CLEdgeNonMaxSuppressionKernel
784 - @ref CLEdgeTraceKernel
785 - @ref CLGaussianPyramidHorKernel
786 - @ref CLGaussianPyramidVertKernel
787 - @ref CLGradientKernel
788 - @ref NEChannelCombineKernel
789 - @ref NEFillArrayKernel
790 - @ref NEGaussianPyramidHorKernel
791 - @ref NEGaussianPyramidVertKernel
Georgios Pinitas09d34512018-08-30 16:02:11 +0100792 - NEHarrisScoreFP16Kernel
Anthony Barbier3762e742018-03-02 11:49:33 +0000793 - @ref NEHarrisScoreKernel
794 - @ref NEHOGDetectorKernel
795 - @ref NELogits1DMaxKernel
796 - NELogits1DShiftExpSumKernel
797 - NELogits1DNormKernel
798 - @ref NENonMaximaSuppression3x3FP16Kernel
799 - @ref NENonMaximaSuppression3x3Kernel
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100800
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100801v17.03.1 First Major public release of the sources
802 - Renamed the library to arm_compute
803 - New CPP target introduced for C++ kernels shared between NEON and CL functions.
804 - New padding calculation interface introduced and ported most kernels / functions to use it.
805 - New OpenCL kernels / functions:
Anthony Barbier3762e742018-03-02 11:49:33 +0000806 - @ref CLGEMMLowpMatrixMultiplyKernel / CLGEMMLowp
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100807 - New NEON kernels / functions:
Anthony Barbier3762e742018-03-02 11:49:33 +0000808 - @ref NENormalizationLayerKernel / @ref NENormalizationLayer
809 - @ref NETransposeKernel / @ref NETranspose
810 - @ref NELogits1DMaxKernel, NELogits1DShiftExpSumKernel, NELogits1DNormKernel / @ref NESoftmaxLayer
811 - @ref NEIm2ColKernel, @ref NECol2ImKernel, NEConvolutionLayerWeightsReshapeKernel / @ref NEConvolutionLayer
812 - @ref NEGEMMMatrixAccumulateBiasesKernel / @ref NEFullyConnectedLayer
813 - @ref NEGEMMLowpMatrixMultiplyKernel / NEGEMMLowp
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100814
815v17.03 Sources preview
816 - New OpenCL kernels / functions:
Anthony Barbier3762e742018-03-02 11:49:33 +0000817 - @ref CLGradientKernel, @ref CLEdgeNonMaxSuppressionKernel, @ref CLEdgeTraceKernel / @ref CLCannyEdge
Gian Marco Iodice5fc07aa2019-05-15 17:08:02 +0100818 - GEMM refactoring + FP16 support: CLGEMMInterleave4x4Kernel, CLGEMMTranspose1xWKernel, @ref CLGEMMMatrixMultiplyKernel, @ref CLGEMMMatrixAdditionKernel / @ref CLGEMM
Anthony Barbier3762e742018-03-02 11:49:33 +0000819 - @ref CLGEMMMatrixAccumulateBiasesKernel / @ref CLFullyConnectedLayer
820 - @ref CLTransposeKernel / @ref CLTranspose
821 - @ref CLLKTrackerInitKernel, @ref CLLKTrackerStage0Kernel, @ref CLLKTrackerStage1Kernel, @ref CLLKTrackerFinalizeKernel / @ref CLOpticalFlow
822 - @ref CLNormalizationLayerKernel / @ref CLNormalizationLayer
823 - @ref CLLaplacianPyramid, @ref CLLaplacianReconstruct
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100824 - New NEON kernels / functions:
Anthony Barbier3762e742018-03-02 11:49:33 +0000825 - @ref NEActivationLayerKernel / @ref NEActivationLayer
826 - GEMM refactoring + FP16 support (Requires armv8.2 CPU): @ref NEGEMMInterleave4x4Kernel, @ref NEGEMMTranspose1xWKernel, @ref NEGEMMMatrixMultiplyKernel, @ref NEGEMMMatrixAdditionKernel / @ref NEGEMM
827 - @ref NEPoolingLayerKernel / @ref NEPoolingLayer
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100828
829v17.02.1 Sources preview
830 - New OpenCL kernels / functions:
Anthony Barbier3762e742018-03-02 11:49:33 +0000831 - @ref CLLogits1DMaxKernel, @ref CLLogits1DShiftExpSumKernel, @ref CLLogits1DNormKernel / @ref CLSoftmaxLayer
832 - @ref CLPoolingLayerKernel / @ref CLPoolingLayer
833 - @ref CLIm2ColKernel, @ref CLCol2ImKernel, CLConvolutionLayerWeightsReshapeKernel / @ref CLConvolutionLayer
834 - @ref CLRemapKernel / @ref CLRemap
835 - @ref CLGaussianPyramidHorKernel, @ref CLGaussianPyramidVertKernel / @ref CLGaussianPyramid, @ref CLGaussianPyramidHalf, @ref CLGaussianPyramidOrb
836 - @ref CLMinMaxKernel, @ref CLMinMaxLocationKernel / @ref CLMinMaxLocation
837 - @ref CLNonLinearFilterKernel / @ref CLNonLinearFilter
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100838 - New NEON FP16 kernels (Requires armv8.2 CPU)
Anthony Barbier3762e742018-03-02 11:49:33 +0000839 - @ref NEAccumulateWeightedFP16Kernel
840 - @ref NEBox3x3FP16Kernel
841 - @ref NENonMaximaSuppression3x3FP16Kernel
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100842
843v17.02 Sources preview
844 - New OpenCL kernels / functions:
Anthony Barbier3762e742018-03-02 11:49:33 +0000845 - @ref CLActivationLayerKernel / @ref CLActivationLayer
846 - @ref CLChannelCombineKernel / @ref CLChannelCombine
847 - @ref CLDerivativeKernel / @ref CLChannelExtract
848 - @ref CLFastCornersKernel / @ref CLFastCorners
849 - @ref CLMeanStdDevKernel / @ref CLMeanStdDev
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100850 - New NEON kernels / functions:
Anthony Barbier3762e742018-03-02 11:49:33 +0000851 - HOG / SVM: @ref NEHOGOrientationBinningKernel, @ref NEHOGBlockNormalizationKernel, @ref NEHOGDetectorKernel, NEHOGNonMaximaSuppressionKernel / @ref NEHOGDescriptor, @ref NEHOGDetector, @ref NEHOGGradient, @ref NEHOGMultiDetection
852 - @ref NENonLinearFilterKernel / @ref NENonLinearFilter
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100853 - Introduced a CLScheduler to manage the default context and command queue used by the runtime library and create synchronisation events.
854 - Switched all the kernels / functions to use tensors instead of images.
855 - Updated documentation to include instructions to build the library from sources.
856
857v16.12 Binary preview release
858 - Original release
859
860@section S3_how_to_build How to build the library and the examples
861
862@subsection S3_1_build_options Build options
863
864scons 2.3 or above is required to build the library.
865To see the build options available simply run ```scons -h```:
866
Anthony Barbier79c61782017-06-23 11:48:24 +0100867 debug: Debug (yes|no)
868 default: False
869 actual: False
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100870
Anthony Barbier79c61782017-06-23 11:48:24 +0100871 asserts: Enable asserts (this flag is forced to 1 for debug=1) (yes|no)
872 default: False
873 actual: False
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100874
Anthony Barbier79c61782017-06-23 11:48:24 +0100875 arch: Target Architecture (armv7a|arm64-v8a|arm64-v8.2-a|x86_32|x86_64)
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100876 default: armv7a
877 actual: armv7a
878
Anthony Barbier79c61782017-06-23 11:48:24 +0100879 os: Target OS (linux|android|bare_metal)
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100880 default: linux
881 actual: linux
882
Anthony Barbier2d0ce772018-02-21 15:35:36 +0000883 build: Build type (native|cross_compile|embed_only)
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100884 default: cross_compile
885 actual: cross_compile
886
Anthony Barbier79c61782017-06-23 11:48:24 +0100887 examples: Build example programs (yes|no)
888 default: True
889 actual: True
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100890
Anthony Barbier79c61782017-06-23 11:48:24 +0100891 Werror: Enable/disable the -Werror compilation flag (yes|no)
892 default: True
893 actual: True
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100894
Anthony Barbier79c61782017-06-23 11:48:24 +0100895 opencl: Enable OpenCL support (yes|no)
896 default: True
897 actual: True
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100898
Anthony Barbier79c61782017-06-23 11:48:24 +0100899 neon: Enable Neon support (yes|no)
900 default: False
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100901 actual: False
902
Anthony Barbier20dbb822017-12-13 21:19:39 +0000903 gles_compute: Enable OpenGL ES Compute Shader support (yes|no)
904 default: False
905 actual: False
906
907 embed_kernels: Embed OpenCL kernels and OpenGL ES compute shader in library binary (yes|no)
Anthony Barbiercc0a80b2017-12-15 11:37:29 +0000908 default: True
909 actual: True
Anthony Barbier79c61782017-06-23 11:48:24 +0100910
911 set_soname: Set the library's soname and shlibversion (requires SCons 2.4 or above) (yes|no)
912 default: False
913 actual: False
914
915 openmp: Enable OpenMP backend (yes|no)
916 default: False
917 actual: False
918
919 cppthreads: Enable C++11 threads backend (yes|no)
920 default: True
921 actual: True
922
923 build_dir: Specify sub-folder for the build ( /path/to/build_dir )
924 default: .
925 actual: .
926
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100927 extra_cxx_flags: Extra CXX flags to be appended to the build command
928 default:
929 actual:
930
Anthony Barbier79c61782017-06-23 11:48:24 +0100931 pmu: Enable PMU counters (yes|no)
932 default: False
933 actual: False
934
Anthony Barbier6a5627a2017-09-26 14:42:02 +0100935 mali: Enable Mali hardware counters (yes|no)
936 default: False
937 actual: False
938
Anthony Barbier79c61782017-06-23 11:48:24 +0100939 validation_tests: Build validation test programs (yes|no)
940 default: False
941 actual: False
942
943 benchmark_tests: Build benchmark test programs (yes|no)
944 default: False
945 actual: False
946
947@b debug / @b asserts:
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100948 - With debug=1 asserts are enabled, and the library is built with symbols and no optimisations enabled.
949 - With debug=0 and asserts=1: Optimisations are enabled and symbols are removed, however all the asserts are still present (This is about 20% slower than the release build)
950 - With debug=0 and asserts=0: All optimisations are enable and no validation is performed, if the application misuses the library it is likely to result in a crash. (Only use this mode once you are sure your application is working as expected).
951
Anthony Barbier79c61782017-06-23 11:48:24 +0100952@b arch: The x86_32 and x86_64 targets can only be used with neon=0 and opencl=1.
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100953
Anthony Barbier79c61782017-06-23 11:48:24 +0100954@b os: Choose the operating system you are targeting: Linux, Android or bare metal.
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100955@note bare metal can only be used for NEON (not OpenCL), only static libraries get built and NEON's multi-threading support is disabled.
956
Anthony Barbier79c61782017-06-23 11:48:24 +0100957@b build: you can either build directly on your device (native) or cross compile from your desktop machine (cross-compile). In both cases make sure the compiler is available in your path.
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100958
Anthony Barbier79c61782017-06-23 11:48:24 +0100959@note If you want to natively compile for 32bit on a 64bit ARM device running a 64bit OS then you will have to use cross-compile too.
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100960
Anthony Barbier2d0ce772018-02-21 15:35:36 +0000961There is also an 'embed_only' option which will generate all the .embed files for the OpenCL kernels and / or OpenGLES compute shaders. This might be useful if using a different build system to compile the library.
962
Anthony Barbier79c61782017-06-23 11:48:24 +0100963@b Werror: If you are compiling using the same toolchains as the ones used in this guide then there shouldn't be any warning and therefore you should be able to keep Werror=1. If with a different compiler version the library fails to build because of warnings interpreted as errors then, if you are sure the warnings are not important, you might want to try to build with Werror=0 (But please do report the issue either on Github or by an email to developer@arm.com so that the issue can be addressed).
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100964
Anthony Barbier20dbb822017-12-13 21:19:39 +0000965@b opencl / @b neon / @b gles_compute: Choose which SIMD technology you want to target. (NEON for ARM Cortex-A CPUs or OpenCL / GLES_COMPUTE for ARM Mali GPUs)
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100966
Anthony Barbier20dbb822017-12-13 21:19:39 +0000967@b embed_kernels: For OpenCL / GLES_COMPUTE only: set embed_kernels=1 if you want the OpenCL / GLES_COMPUTE kernels to be built in the library's binaries instead of being read from separate ".cl" / ".cs" files. If embed_kernels is set to 0 then the application can set the path to the folder containing the OpenCL / GLES_COMPUTE kernel files by calling CLKernelLibrary::init() / GCKernelLibrary::init(). By default the path is set to "./cl_kernels" / "./cs_shaders".
Anthony Barbier79c61782017-06-23 11:48:24 +0100968
969@b set_soname: Do you want to build the versioned version of the library ?
970
Anthony Barbier6ff3b192017-09-04 18:44:23 +0100971If enabled the library will contain a SONAME and SHLIBVERSION and some symlinks will automatically be created between the objects.
972Example:
973 libarm_compute_core.so -> libarm_compute_core.so.1.0.0
974 libarm_compute_core.so.1 -> libarm_compute_core.so.1.0.0
975 libarm_compute_core.so.1.0.0
976
977@note This options is disabled by default as it requires SCons version 2.4 or above.
978
Anthony Barbier79c61782017-06-23 11:48:24 +0100979@b extra_cxx_flags: Custom CXX flags which will be appended to the end of the build command.
980
981@b build_dir: Build the library in a subfolder of the "build" folder. (Allows to build several configurations in parallel).
982
983@b examples: Build or not the examples
984
985@b validation_tests: Enable the build of the validation suite.
986
Anthony Barbier79c61782017-06-23 11:48:24 +0100987@b benchmark_tests: Enable the build of the benchmark tests
988
989@b pmu: Enable the PMU cycle counter to measure execution time in benchmark tests. (Your device needs to support it)
990
Anthony Barbier6a5627a2017-09-26 14:42:02 +0100991@b mali: Enable the collection of Mali hardware counters to measure execution time in benchmark tests. (Your device needs to have a Mali driver that supports it)
992
Anthony Barbier79c61782017-06-23 11:48:24 +0100993@b openmp Build in the OpenMP scheduler for NEON.
994
995@note Only works when building with g++ not clang++
996
997@b cppthreads Build in the C++11 scheduler for NEON.
998
Anthony Barbier3762e742018-03-02 11:49:33 +0000999@sa Scheduler::set
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001000
Moritz Pflanzer07674de2017-07-21 09:39:36 +01001001@subsection S3_2_linux Building for Linux
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001002
1003@subsubsection S3_2_1_library How to build the library ?
1004
1005For Linux, the library was successfully built and tested using the following Linaro GCC toolchain:
1006
Michele Di Giorgio6513ccb2018-08-28 14:38:35 +01001007 - gcc-linaro-4.9-2016.02-x86_64_arm-linux-gnueabihf
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001008 - gcc-linaro-4.9-2016.02-x86_64_aarch64-linux-gnu
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001009
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001010To cross-compile the library in debug mode, with NEON only support, for Linux 32bit:
1011
1012 scons Werror=1 -j8 debug=1 neon=1 opencl=0 os=linux arch=armv7a
1013
1014To cross-compile the library in asserts mode, with OpenCL only support, for Linux 64bit:
1015
1016 scons Werror=1 -j8 debug=0 asserts=1 neon=0 opencl=1 embed_kernels=1 os=linux arch=arm64-v8a
1017
Anthony Barbier20dbb822017-12-13 21:19:39 +00001018To cross-compile the library in asserts mode, with GLES_COMPUTE only support, for Linux 64bit:
1019
1020 scons Werror=1 -j8 debug=0 asserts=1 neon=0 opencl=0 gles_compute=1 embed_kernels=1 os=linux arch=arm64-v8a
1021
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001022You can also compile the library natively on an ARM device by using <b>build=native</b>:
1023
1024 scons Werror=1 -j8 debug=0 neon=1 opencl=0 os=linux arch=arm64-v8a build=native
1025 scons Werror=1 -j8 debug=0 neon=1 opencl=0 os=linux arch=armv7a build=native
1026
1027@note g++ for ARM is mono-arch, therefore if you want to compile for Linux 32bit on a Linux 64bit platform you will have to use a cross compiler.
1028
1029For example on a 64bit Debian based system you would have to install <b>g++-arm-linux-gnueabihf</b>
1030
1031 apt-get install g++-arm-linux-gnueabihf
1032
1033Then run
1034
1035 scons Werror=1 -j8 debug=0 neon=1 opencl=0 os=linux arch=armv7a build=cross_compile
1036
1037or simply remove the build parameter as build=cross_compile is the default value:
1038
1039 scons Werror=1 -j8 debug=0 neon=1 opencl=0 os=linux arch=armv7a
1040
1041@attention To cross compile with opencl=1 you need to make sure to have a version of libOpenCL matching your target architecture.
1042
1043@subsubsection S3_2_2_examples How to manually build the examples ?
1044
1045The examples get automatically built by scons as part of the build process of the library described above. This section just describes how you can build and link your own application against our library.
1046
Georgios Pinitasd9eb2752018-04-03 13:44:29 +01001047@note The following command lines assume the arm_compute binaries are present in the current directory or in the system library path. If this is not the case you can specify the location of the pre-built library with the compiler option -L. When building the OpenCL example the commands below assume that the CL headers are located in the include folder where the command is executed.
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001048
1049To cross compile a NEON example for Linux 32bit:
1050
Anthony Barbierb2881fc2017-09-29 17:12:12 +01001051 arm-linux-gnueabihf-g++ examples/neon_convolution.cpp utils/Utils.cpp -I. -Iinclude -std=c++11 -mfpu=neon -L. -larm_compute -larm_compute_core -o neon_convolution
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001052
1053To cross compile a NEON example for Linux 64bit:
1054
Anthony Barbierb2881fc2017-09-29 17:12:12 +01001055 aarch64-linux-gnu-g++ examples/neon_convolution.cpp utils/Utils.cpp -I. -Iinclude -std=c++11 -L. -larm_compute -larm_compute_core -o neon_convolution
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001056
1057(notice the only difference with the 32 bit command is that we don't need the -mfpu option and the compiler's name is different)
1058
1059To cross compile an OpenCL example for Linux 32bit:
1060
Georgios Pinitasd9eb2752018-04-03 13:44:29 +01001061 arm-linux-gnueabihf-g++ examples/cl_convolution.cpp utils/Utils.cpp -I. -Iinclude -std=c++11 -mfpu=neon -L. -larm_compute -larm_compute_core -o cl_convolution -DARM_COMPUTE_CL
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001062
1063To cross compile an OpenCL example for Linux 64bit:
1064
Georgios Pinitasd9eb2752018-04-03 13:44:29 +01001065 aarch64-linux-gnu-g++ examples/cl_convolution.cpp utils/Utils.cpp -I. -Iinclude -std=c++11 -L. -larm_compute -larm_compute_core -o cl_convolution -DARM_COMPUTE_CL
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001066
Anthony Barbier14c86a92017-12-14 16:27:41 +00001067To cross compile a GLES example for Linux 32bit:
1068
1069 arm-linux-gnueabihf-g++ examples/gc_absdiff.cpp utils/Utils.cpp -I. -Iinclude/ -L. -larm_compute -larm_compute_core -std=c++11 -mfpu=neon -DARM_COMPUTE_GC -Iinclude/linux/ -o gc_absdiff
1070
1071To cross compile a GLES example for Linux 64bit:
1072
1073 aarch64-linux-gnu-g++ examples/gc_absdiff.cpp utils/Utils.cpp -I. -Iinclude/ -L. -larm_compute -larm_compute_core -std=c++11 -DARM_COMPUTE_GC -Iinclude/linux/ -o gc_absdiff
1074
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001075(notice the only difference with the 32 bit command is that we don't need the -mfpu option and the compiler's name is different)
1076
Anthony Barbier14c86a92017-12-14 16:27:41 +00001077To cross compile the examples with the Graph API, such as graph_lenet.cpp, you need to link the examples against arm_compute_graph.so too.
1078
1079@note The compute library must currently be built with both neon and opencl enabled - neon=1 and opencl=1
Gian Marco Iodicedaec1aa2017-09-29 12:03:18 +01001080
1081i.e. to cross compile the "graph_lenet" example for Linux 32bit:
1082
Georgios Pinitas12be7ab2018-07-03 12:06:23 +01001083 arm-linux-gnueabihf-g++ examples/graph_lenet.cpp utils/Utils.cpp utils/GraphUtils.cpp utils/CommonGraphOptions.cpp -I. -Iinclude -std=c++11 -mfpu=neon -L. -larm_compute_graph -larm_compute -larm_compute_core -Wl,--allow-shlib-undefined -o graph_lenet
Gian Marco Iodicedaec1aa2017-09-29 12:03:18 +01001084
1085i.e. to cross compile the "graph_lenet" example for Linux 64bit:
1086
Georgios Pinitas12be7ab2018-07-03 12:06:23 +01001087 aarch64-linux-gnu-g++ examples/graph_lenet.cpp utils/Utils.cpp utils/GraphUtils.cpp utils/CommonGraphOptions.cpp -I. -Iinclude -std=c++11 -L. -larm_compute_graph -larm_compute -larm_compute_core -Wl,--allow-shlib-undefined -o graph_lenet
Gian Marco Iodicedaec1aa2017-09-29 12:03:18 +01001088
1089(notice the only difference with the 32 bit command is that we don't need the -mfpu option and the compiler's name is different)
1090
Anthony Barbiere5007472017-10-27 15:01:44 +01001091@note If compiling using static libraries, this order must be followed when linking: arm_compute_graph_static, arm_compute, arm_compute_core
1092
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001093To compile natively (i.e directly on an ARM device) for NEON for Linux 32bit:
1094
Anthony Barbierb2881fc2017-09-29 17:12:12 +01001095 g++ examples/neon_convolution.cpp utils/Utils.cpp -I. -Iinclude -std=c++11 -mfpu=neon -larm_compute -larm_compute_core -o neon_convolution
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001096
1097To compile natively (i.e directly on an ARM device) for NEON for Linux 64bit:
1098
Anthony Barbierb2881fc2017-09-29 17:12:12 +01001099 g++ examples/neon_convolution.cpp utils/Utils.cpp -I. -Iinclude -std=c++11 -larm_compute -larm_compute_core -o neon_convolution
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001100
1101(notice the only difference with the 32 bit command is that we don't need the -mfpu option)
1102
1103To compile natively (i.e directly on an ARM device) for OpenCL for Linux 32bit or Linux 64bit:
1104
Georgios Pinitasd9eb2752018-04-03 13:44:29 +01001105 g++ examples/cl_convolution.cpp utils/Utils.cpp -I. -Iinclude -std=c++11 -larm_compute -larm_compute_core -o cl_convolution -DARM_COMPUTE_CL
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001106
Anthony Barbier14c86a92017-12-14 16:27:41 +00001107To compile natively (i.e directly on an ARM device) for GLES for Linux 32bit or Linux 64bit:
Gian Marco Iodicedaec1aa2017-09-29 12:03:18 +01001108
Anthony Barbier14c86a92017-12-14 16:27:41 +00001109 g++ examples/gc_absdiff.cpp utils/Utils.cpp -I. -Iinclude/ -L. -larm_compute -larm_compute_core -std=c++11 -DARM_COMPUTE_GC -Iinclude/linux/ -o gc_absdiff
1110
1111To compile natively the examples with the Graph API, such as graph_lenet.cpp, you need to link the examples against arm_compute_graph.so too.
1112@note The compute library must currently be built with both neon and opencl enabled - neon=1 and opencl=1
1113
1114i.e. to natively compile the "graph_lenet" example for Linux 32bit:
Gian Marco Iodicedaec1aa2017-09-29 12:03:18 +01001115
Georgios Pinitas12be7ab2018-07-03 12:06:23 +01001116 g++ examples/graph_lenet.cpp utils/Utils.cpp utils/GraphUtils.cpp utils/CommonGraphOptions.cpp -I. -Iinclude -std=c++11 -mfpu=neon -L. -larm_compute_graph -larm_compute -larm_compute_core -Wl,--allow-shlib-undefined -o graph_lenet
Gian Marco Iodicedaec1aa2017-09-29 12:03:18 +01001117
Anthony Barbier14c86a92017-12-14 16:27:41 +00001118i.e. to natively compile the "graph_lenet" example for Linux 64bit:
Gian Marco Iodicedaec1aa2017-09-29 12:03:18 +01001119
Georgios Pinitas12be7ab2018-07-03 12:06:23 +01001120 g++ examples/graph_lenet.cpp utils/Utils.cpp utils/GraphUtils.cpp utils/CommonGraphOptions.cpp -I. -Iinclude -std=c++11 L. -larm_compute_graph -larm_compute -larm_compute_core -Wl,--allow-shlib-undefined -o graph_lenet
Gian Marco Iodicedaec1aa2017-09-29 12:03:18 +01001121
1122(notice the only difference with the 32 bit command is that we don't need the -mfpu option)
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001123
Anthony Barbiere5007472017-10-27 15:01:44 +01001124@note If compiling using static libraries, this order must be followed when linking: arm_compute_graph_static, arm_compute, arm_compute_core
1125
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001126@note These two commands assume libarm_compute.so is available in your library path, if not add the path to it using -L
1127
1128To run the built executable simply run:
1129
1130 LD_LIBRARY_PATH=build ./neon_convolution
1131
1132or
1133
1134 LD_LIBRARY_PATH=build ./cl_convolution
1135
Georgios Pinitas9f28b392018-07-18 20:01:53 +01001136@note Examples accept different types of arguments, to find out what they are run the example with \a --help as an argument. If no arguments are specified then random values will be used to execute the graph.
Anthony Barbier3762e742018-03-02 11:49:33 +00001137
1138For example:
Anthony Barbier38e7f1f2018-05-21 13:37:47 +01001139
Georgios Pinitas9f28b392018-07-18 20:01:53 +01001140 LD_LIBRARY_PATH=. ./graph_lenet --help
Anthony Barbier3762e742018-03-02 11:49:33 +00001141
Georgios Pinitas9f28b392018-07-18 20:01:53 +01001142Below is a list of the common parameters among the graph examples :
1143@snippet utils/CommonGraphOptions.h Common graph examples parameters
Anthony Barbier3762e742018-03-02 11:49:33 +00001144
Moritz Pflanzer07674de2017-07-21 09:39:36 +01001145@subsection S3_3_android Building for Android
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001146
1147For Android, the library was successfully built and tested using Google's standalone toolchains:
Anthony Barbierd51ea0a2018-08-07 17:48:03 +01001148 - clang++ from NDK r17b for armv7a
1149 - clang++ from NDK r17b for arm64-v8a
Anthony Barbier3a6163e2018-08-10 17:36:36 +01001150 - clang++ from NDK r18-beta1 for arm64-v8.2-a with FP16 support
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001151
1152Here is a guide to <a href="https://developer.android.com/ndk/guides/standalone_toolchain.html">create your Android standalone toolchains from the NDK</a>
1153
Anthony Barbierd51ea0a2018-08-07 17:48:03 +01001154- Download the NDK r17b from here: https://developer.android.com/ndk/downloads/index.html
Georgios Pinitasf112ede2019-03-01 19:11:20 +00001155- Make sure you have Python 2.7 installed on your machine.
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001156- Generate the 32 and/or 64 toolchains by running the following commands:
1157
Anthony Barbier38e7f1f2018-05-21 13:37:47 +01001158
Anthony Barbierd51ea0a2018-08-07 17:48:03 +01001159 $NDK/build/tools/make_standalone_toolchain.py --arch arm64 --install-dir $MY_TOOLCHAINS/aarch64-linux-android-ndk-r17b --stl libc++ --api 21
1160 $NDK/build/tools/make_standalone_toolchain.py --arch arm --install-dir $MY_TOOLCHAINS/arm-linux-android-ndk-r17b --stl libc++ --api 21
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001161
Anthony Barbierd51ea0a2018-08-07 17:48:03 +01001162@attention We used to use gnustl but as of NDK r17 it is deprecated so we switched to libc++
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001163
Anthony Barbier38e7f1f2018-05-21 13:37:47 +01001164@note Make sure to add the toolchains to your PATH:
1165
Anthony Barbierd51ea0a2018-08-07 17:48:03 +01001166 export PATH=$PATH:$MY_TOOLCHAINS/aarch64-linux-android-ndk-r17b/bin:$MY_TOOLCHAINS/arm-linux-android-ndk-r17b/bin
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001167
1168@subsubsection S3_3_1_library How to build the library ?
1169
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001170To cross-compile the library in debug mode, with NEON only support, for Android 32bit:
1171
1172 CXX=clang++ CC=clang scons Werror=1 -j8 debug=1 neon=1 opencl=0 os=android arch=armv7a
1173
1174To cross-compile the library in asserts mode, with OpenCL only support, for Android 64bit:
1175
Anthony Barbier14c86a92017-12-14 16:27:41 +00001176 CXX=clang++ CC=clang scons Werror=1 -j8 debug=0 asserts=1 neon=0 opencl=1 embed_kernels=1 os=android arch=arm64-v8a
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001177
Anthony Barbier20dbb822017-12-13 21:19:39 +00001178To cross-compile the library in asserts mode, with GLES_COMPUTE only support, for Android 64bit:
1179
Anthony Barbier14c86a92017-12-14 16:27:41 +00001180 CXX=clang++ CC=clang scons Werror=1 -j8 debug=0 asserts=1 neon=0 opencl=0 gles_compute=1 embed_kernels=1 os=android arch=arm64-v8a
Anthony Barbier20dbb822017-12-13 21:19:39 +00001181
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001182@subsubsection S3_3_2_examples How to manually build the examples ?
1183
1184The examples get automatically built by scons as part of the build process of the library described above. This section just describes how you can build and link your own application against our library.
1185
Georgios Pinitasd9eb2752018-04-03 13:44:29 +01001186@note The following command lines assume the arm_compute binaries are present in the current directory or in the system library path. If this is not the case you can specify the location of the pre-built library with the compiler option -L. When building the OpenCL example the commands below assume that the CL headers are located in the include folder where the command is executed.
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001187
1188Once you've got your Android standalone toolchain built and added to your path you can do the following:
1189
1190To cross compile a NEON example:
1191
1192 #32 bit:
Georgios Pinitas9873ea32017-12-05 15:28:55 +00001193 arm-linux-androideabi-clang++ examples/neon_convolution.cpp utils/Utils.cpp -I. -Iinclude -std=c++11 -larm_compute-static -larm_compute_core-static -L. -o neon_convolution_arm -static-libstdc++ -pie
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001194 #64 bit:
Anthony Barbier14c86a92017-12-14 16:27:41 +00001195 aarch64-linux-android-clang++ examples/neon_convolution.cpp utils/Utils.cpp -I. -Iinclude -std=c++11 -larm_compute-static -larm_compute_core-static -L. -o neon_convolution_aarch64 -static-libstdc++ -pie
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001196
1197To cross compile an OpenCL example:
1198
1199 #32 bit:
Georgios Pinitasd9eb2752018-04-03 13:44:29 +01001200 arm-linux-androideabi-clang++ examples/cl_convolution.cpp utils/Utils.cpp -I. -Iinclude -std=c++11 -larm_compute-static -larm_compute_core-static -L. -o cl_convolution_arm -static-libstdc++ -pie -DARM_COMPUTE_CL
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001201 #64 bit:
Georgios Pinitasd9eb2752018-04-03 13:44:29 +01001202 aarch64-linux-android-clang++ examples/cl_convolution.cpp utils/Utils.cpp -I. -Iinclude -std=c++11 -larm_compute-static -larm_compute_core-static -L. -o cl_convolution_aarch64 -static-libstdc++ -pie -DARM_COMPUTE_CL
Anthony Barbier14c86a92017-12-14 16:27:41 +00001203
1204To cross compile a GLES example:
Anthony Barbiercc0a80b2017-12-15 11:37:29 +00001205
Anthony Barbier14c86a92017-12-14 16:27:41 +00001206 #32 bit:
1207 arm-linux-androideabi-clang++ examples/gc_absdiff.cpp utils/Utils.cpp -I. -Iinclude -std=c++11 -larm_compute-static -larm_compute_core-static -L. -o gc_absdiff_arm -static-libstdc++ -pie -DARM_COMPUTE_GC
1208 #64 bit:
1209 aarch64-linux-android-clang++ examples/gc_absdiff.cpp utils/Utils.cpp -I. -Iinclude -std=c++11 -larm_compute-static -larm_compute_core-static -L. -o gc_absdiff_aarch64 -static-libstdc++ -pie -DARM_COMPUTE_GC
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001210
Gian Marco Iodicedaec1aa2017-09-29 12:03:18 +01001211To cross compile the examples with the Graph API, such as graph_lenet.cpp, you need to link the library arm_compute_graph also.
1212(notice the compute library has to be built with both neon and opencl enabled - neon=1 and opencl=1)
1213
1214 #32 bit:
Georgios Pinitas12be7ab2018-07-03 12:06:23 +01001215 arm-linux-androideabi-clang++ examples/graph_lenet.cpp utils/Utils.cpp utils/GraphUtils.cpp utils/CommonGraphOptions.cpp -I. -Iinclude -std=c++11 -Wl,--whole-archive -larm_compute_graph-static -Wl,--no-whole-archive -larm_compute-static -larm_compute_core-static -L. -o graph_lenet_arm -static-libstdc++ -pie -DARM_COMPUTE_CL
Gian Marco Iodicedaec1aa2017-09-29 12:03:18 +01001216 #64 bit:
Georgios Pinitas12be7ab2018-07-03 12:06:23 +01001217 aarch64-linux-android-clang++ examples/graph_lenet.cpp utils/Utils.cpp utils/GraphUtils.cpp utils/CommonGraphOptions.cpp -I. -Iinclude -std=c++11 -Wl,--whole-archive -larm_compute_graph-static -Wl,--no-whole-archive -larm_compute-static -larm_compute_core-static -L. -o graph_lenet_aarch64 -static-libstdc++ -pie -DARM_COMPUTE_CL
Gian Marco Iodicedaec1aa2017-09-29 12:03:18 +01001218
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001219@note Due to some issues in older versions of the Mali OpenCL DDK (<= r13p0), we recommend to link arm_compute statically on Android.
Anthony Barbier20dbb822017-12-13 21:19:39 +00001220@note When linked statically the arm_compute_graph library currently needs the --whole-archive linker flag in order to work properly
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001221
1222Then you need to do is upload the executable and the shared library to the device using ADB:
1223
1224 adb push neon_convolution_arm /data/local/tmp/
1225 adb push cl_convolution_arm /data/local/tmp/
Anthony Barbier14c86a92017-12-14 16:27:41 +00001226 adb push gc_absdiff_arm /data/local/tmp/
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001227 adb shell chmod 777 -R /data/local/tmp/
1228
1229And finally to run the example:
1230
1231 adb shell /data/local/tmp/neon_convolution_arm
1232 adb shell /data/local/tmp/cl_convolution_arm
Anthony Barbier14c86a92017-12-14 16:27:41 +00001233 adb shell /data/local/tmp/gc_absdiff_arm
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001234
1235For 64bit:
1236
1237 adb push neon_convolution_aarch64 /data/local/tmp/
1238 adb push cl_convolution_aarch64 /data/local/tmp/
Anthony Barbier14c86a92017-12-14 16:27:41 +00001239 adb push gc_absdiff_aarch64 /data/local/tmp/
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001240 adb shell chmod 777 -R /data/local/tmp/
1241
1242And finally to run the example:
1243
1244 adb shell /data/local/tmp/neon_convolution_aarch64
1245 adb shell /data/local/tmp/cl_convolution_aarch64
Anthony Barbier14c86a92017-12-14 16:27:41 +00001246 adb shell /data/local/tmp/gc_absdiff_aarch64
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001247
Georgios Pinitas9f28b392018-07-18 20:01:53 +01001248@note Examples accept different types of arguments, to find out what they are run the example with \a --help as an argument. If no arguments are specified then random values will be used to execute the graph.
Anthony Barbier3762e742018-03-02 11:49:33 +00001249
1250For example:
Georgios Pinitas9f28b392018-07-18 20:01:53 +01001251 adb shell /data/local/tmp/graph_lenet --help
Anthony Barbier3762e742018-03-02 11:49:33 +00001252
1253In this case the first argument of LeNet (like all the graph examples) is the target (i.e 0 to run on NEON, 1 to run on OpenCL if available, 2 to run on OpenCL using the CLTuner), the second argument is the path to the folder containing the npy files for the weights and finally the third argument is the number of batches to run.
1254
Michalis Spyrou6e52ba32017-10-04 15:40:38 +01001255@subsection S3_4_bare_metal Building for bare metal
1256
1257For bare metal, the library was successfully built using linaros's latest (gcc-linaro-6.3.1-2017.05) bare metal toolchains:
1258 - arm-eabi for armv7a
1259 - aarch64-elf for arm64-v8a
1260
1261Download linaro for <a href="https://releases.linaro.org/components/toolchain/binaries/6.3-2017.05/arm-eabi/">armv7a</a> and <a href="https://releases.linaro.org/components/toolchain/binaries/6.3-2017.05/aarch64-elf/">arm64-v8a</a>.
1262
1263@note Make sure to add the toolchains to your PATH: export PATH=$PATH:$MY_TOOLCHAINS/gcc-linaro-6.3.1-2017.05-x86_64_aarch64-elf/bin:$MY_TOOLCHAINS/gcc-linaro-6.3.1-2017.05-x86_64_arm-eabi/bin
1264
1265@subsubsection S3_4_1_library How to build the library ?
1266
1267To cross-compile the library with NEON support for baremetal arm64-v8a:
1268
1269 scons Werror=1 -j8 debug=0 neon=1 opencl=0 os=bare_metal arch=arm64-v8a build=cross_compile cppthreads=0 openmp=0 standalone=1
1270
1271@subsubsection S3_4_2_examples How to manually build the examples ?
1272
1273Examples are disabled when building for bare metal. If you want to build the examples you need to provide a custom bootcode depending on the target architecture and link against the compute library. More information about bare metal bootcode can be found <a href="http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.dai0527a/index.html">here</a>.
1274
1275@subsection S3_5_windows_host Building on a Windows host system
Moritz Pflanzer07674de2017-07-21 09:39:36 +01001276
1277Using `scons` directly from the Windows command line is known to cause
1278problems. The reason seems to be that if `scons` is setup for cross-compilation
1279it gets confused about Windows style paths (using backslashes). Thus it is
1280recommended to follow one of the options outlined below.
1281
Michalis Spyrou6e52ba32017-10-04 15:40:38 +01001282@subsubsection S3_5_1_ubuntu_on_windows Bash on Ubuntu on Windows
Moritz Pflanzer07674de2017-07-21 09:39:36 +01001283
Gian Marco Iodice5fc07aa2019-05-15 17:08:02 +01001284The best and easiest option is to use
1285<a href="https://msdn.microsoft.com/en-gb/commandline/wsl/about">Ubuntu on Windows</a>.
Moritz Pflanzer07674de2017-07-21 09:39:36 +01001286This feature is still marked as *beta* and thus might not be available.
1287However, if it is building the library is as simple as opening a *Bash on
1288Ubuntu on Windows* shell and following the general guidelines given above.
1289
Michalis Spyrou6e52ba32017-10-04 15:40:38 +01001290@subsubsection S3_5_2_cygwin Cygwin
Moritz Pflanzer07674de2017-07-21 09:39:36 +01001291
Gian Marco Iodice5fc07aa2019-05-15 17:08:02 +01001292If the Windows subsystem for Linux is not available <a href="https://www.cygwin.com/">Cygwin</a>
Pablo Tello78a5d222019-08-06 10:09:18 +01001293can be used to install and run `scons`, the minimum Cygwin version must be 3.0.7 or later. In addition
1294to the default packages installed by Cygwin `scons` has to be selected in the installer. (`git` might
Moritz Pflanzer07674de2017-07-21 09:39:36 +01001295also be useful but is not strictly required if you already have got the source
Gian Marco Iodice5fc07aa2019-05-15 17:08:02 +01001296code of the library.) Linaro provides pre-built versions of
1297<a href="http://releases.linaro.org/components/toolchain/binaries/">GCC cross-compilers</a>
Moritz Pflanzer07674de2017-07-21 09:39:36 +01001298that can be used from the Cygwin terminal. When building for Android the
1299compiler is included in the Android standalone toolchain. After everything has
1300been set up in the Cygwin terminal the general guide on building the library
1301can be followed.
1302
Michalis Spyrou6e52ba32017-10-04 15:40:38 +01001303@subsection S3_6_cl_stub_library The OpenCL stub library
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001304
1305In the opencl-1.2-stubs folder you will find the sources to build a stub OpenCL library which then can be used to link your application or arm_compute against.
1306
1307If you preferred you could retrieve the OpenCL library from your device and link against this one but often this library will have dependencies on a range of system libraries forcing you to link your application against those too even though it is not using them.
1308
1309@warning This OpenCL library provided is a stub and *not* a real implementation. You can use it to resolve OpenCL's symbols in arm_compute while building the example but you must make sure the real libOpenCL.so is in your PATH when running the example or it will not work.
1310
1311To cross-compile the stub OpenCL library simply run:
1312
1313 <target-prefix>-gcc -o libOpenCL.so -Iinclude opencl-1.2-stubs/opencl_stubs.c -fPIC -shared
1314
1315For example:
1316
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001317 #Linux 32bit
1318 arm-linux-gnueabihf-gcc -o libOpenCL.so -Iinclude opencl-1.2-stubs/opencl_stubs.c -fPIC -shared
1319 #Linux 64bit
1320 aarch64-linux-gnu-gcc -o libOpenCL.so -Iinclude -shared opencl-1.2-stubs/opencl_stubs.c -fPIC
1321 #Android 32bit
1322 arm-linux-androideabi-clang -o libOpenCL.so -Iinclude -shared opencl-1.2-stubs/opencl_stubs.c -fPIC -shared
1323 #Android 64bit
Anthony Barbier14c86a92017-12-14 16:27:41 +00001324 aarch64-linux-android-clang -o libOpenCL.so -Iinclude -shared opencl-1.2-stubs/opencl_stubs.c -fPIC -shared
1325
1326@subsection S3_7_gles_stub_library The Linux OpenGLES and EGL stub libraries
1327
1328In the opengles-3.1-stubs folder you will find the sources to build stub EGL and OpenGLES libraries which then can be used to link your Linux application of arm_compute against.
1329
1330@note The stub libraries are only needed on Linux. For Android, the NDK toolchains already provide the meta-EGL and meta-GLES libraries.
1331
1332To cross-compile the stub OpenGLES and EGL libraries simply run:
1333
1334 <target-prefix>-gcc -o libEGL.so -Iinclude/linux opengles-3.1-stubs/EGL.c -fPIC -shared
1335 <target-prefix>-gcc -o libGLESv2.so -Iinclude/linux opengles-3.1-stubs/GLESv2.c -fPIC -shared
1336
1337 #Linux 32bit
1338 arm-linux-gnueabihf-gcc -o libEGL.so -Iinclude/linux opengles-3.1-stubs/EGL.c -fPIC -shared
1339 arm-linux-gnueabihf-gcc -o libGLESv2.so -Iinclude/linux opengles-3.1-stubs/GLESv2.c -fPIC -shared
1340
1341 #Linux 64bit
1342 aarch64-linux-gnu-gcc -o libEGL.so -Iinclude/linux opengles-3.1-stubs/EGL.c -fPIC -shared
1343 aarch64-linux-gnu-gcc -o libGLESv2.so -Iinclude/linux opengles-3.1-stubs/GLESv2.c -fPIC -shared
Georgios Pinitasd9cb0572018-07-16 12:23:09 +01001344
1345@subsection S3_8_cl_requirements OpenCL DDK Requirements
1346
1347@subsubsection S3_8_1_cl_hard_requirements Hard Requirements
1348
1349Compute Library requires OpenCL 1.1 and above with support of non uniform workgroup sizes, which is officially supported in the Mali OpenCL DDK r8p0 and above as an extension (respective extension flag is \a -cl-arm-non-uniform-work-group-size).
1350
1351Enabling 16-bit floating point calculations require \a cl_khr_fp16 extension to be supported. All Mali GPUs with compute capabilities have native support for half precision floating points.
1352
1353Use of @ref CLMeanStdDev function requires 64-bit atomics support, thus \a cl_khr_int64_base_atomics should be supported in order to use.
1354
1355@subsubsection S3_8_2_cl_performance_requirements Performance improvements
1356
1357Integer dot product built-in function extensions (and therefore optimized kernels) are available with Mali OpenCL DDK r22p0 and above for the following GPUs : G71, G76. The relevant extensions are \a cl_arm_integer_dot_product_int8, \a cl_arm_integer_dot_product_accumulate_int8 and \a cl_arm_integer_dot_product_accumulate_int16.
1358
1359OpenCL kernel level debugging can be simplified with the use of printf, this requires the \a cl_arm_printf extension to be supported.
1360
1361SVM allocations are supported for all the underlying allocations in Compute Library. To enable this OpenCL 2.0 and above is a requirement.
Gian Marco Iodice201cea12018-07-30 17:21:41 +01001362
1363@subsection S3_9_cl_tuner OpenCL Tuner
1364
1365The OpenCL tuner, a.k.a. CLTuner, is a module of Arm Compute Library that can improve the performance of the OpenCL kernels tuning the Local-Workgroup-Size (LWS).
1366The optimal LWS for each unique OpenCL kernel configuration is stored in a table. This table can be either imported or exported from/to a file.
Vidhya Sudhan Loganathandc5d3432019-04-29 11:44:11 +01001367The OpenCL tuner runs the same OpenCL kernel for a range of local workgroup sizes and keeps the local workgroup size of the fastest run to use in subsequent calls to the kernel. It supports three modes of tuning with different trade-offs between the time taken to tune and the kernel execution time achieved using the best LWS found. In the Exhaustive mode, it searches all the supported values of LWS. This mode takes the longest time to tune and is the most likely to find the optimal LWS. Normal mode searches a subset of LWS values to yield a good approximation of the optimal LWS. It takes less time to tune than Exhaustive mode. Rapid mode takes the shortest time to tune and finds an LWS value that is at least as good or better than the default LWS value. The mode affects only the search for the optimal LWS and has no effect when the LWS value is imported from a file.
Gian Marco Iodice201cea12018-07-30 17:21:41 +01001368In order for the performance numbers to be meaningful you must disable the GPU power management and set it to a fixed frequency for the entire duration of the tuning phase.
1369
1370If you wish to know more about LWS and the important role on improving the GPU cache utilization, we suggest having a look at the presentation "Even Faster CNNs: Exploring the New Class of Winograd Algorithms available at the following link:
1371
1372https://www.embedded-vision.com/platinum-members/arm/embedded-vision-training/videos/pages/may-2018-embedded-vision-summit-iodice
1373
1374Tuning a network from scratch can be long and affect considerably the execution time for the first run of your network. It is recommended for this reason to store the CLTuner's result in a file to amortize this time when you either re-use the same network or the functions with the same configurations. The tuning is performed only once for each OpenCL kernel.
1375
1376CLTuner looks for the optimal LWS for each unique OpenCL kernel configuration. Since a function (i.e. Convolution Layer, Pooling Layer, Fully Connected Layer ...) can be called multiple times but with different parameters, we associate an "id" (called "config_id") to each kernel to distinguish the unique configurations.
1377
1378 #Example: 2 unique Matrix Multiply configurations
1379@code{.cpp}
1380 TensorShape a0 = TensorShape(32,32);
1381 TensorShape b0 = TensorShape(32,32);
1382 TensorShape c0 = TensorShape(32,32);
1383 TensorShape a1 = TensorShape(64,64);
1384 TensorShape b1 = TensorShape(64,64);
1385 TensorShape c1 = TensorShape(64,64);
1386
1387 Tensor a0_tensor;
1388 Tensor b0_tensor;
1389 Tensor c0_tensor;
1390 Tensor a1_tensor;
1391 Tensor b1_tensor;
1392 Tensor c1_tensor;
1393
1394 a0_tensor.allocator()->init(TensorInfo(a0, 1, DataType::F32));
1395 b0_tensor.allocator()->init(TensorInfo(b0, 1, DataType::F32));
1396 c0_tensor.allocator()->init(TensorInfo(c0, 1, DataType::F32));
1397 a1_tensor.allocator()->init(TensorInfo(a1, 1, DataType::F32));
1398 b1_tensor.allocator()->init(TensorInfo(b1, 1, DataType::F32));
1399 c1_tensor.allocator()->init(TensorInfo(c1 1, DataType::F32));
1400
1401 CLGEMM gemm0;
1402 CLGEMM gemm1;
1403
1404 // Configuration 0
1405 gemm0.configure(&a0, &b0, nullptr, &c0, 1.0f, 0.0f);
1406
1407 // Configuration 1
1408 gemm1.configure(&a1, &b1, nullptr, &c1, 1.0f, 0.0f);
1409@endcode
1410
1411@subsubsection S3_9_1_cl_tuner_how_to How to use it
1412
1413All the graph examples in the ACL's folder "examples" and the arm_compute_benchmark accept an argument to enable the OpenCL tuner and an argument to export/import the LWS values to/from a file
1414
1415 #Enable CL tuner
1416 ./graph_mobilenet --enable-tuner –-target=CL
1417 ./arm_compute_benchmark --enable-tuner
1418
1419 #Export/Import to/from a file
1420 ./graph_mobilenet --enable-tuner --target=CL --tuner-file=acl_tuner.csv
1421 ./arm_compute_benchmark --enable-tuner --tuner-file=acl_tuner.csv
1422
1423If you are importing the CLTuner'results from a file, the new tuned LWS values will be appended to it.
1424
1425Either you are benchmarking the graph examples or the test cases in the arm_compute_benchmark remember to:
1426
1427 -# Disable the power management
1428 -# Keep the GPU frequency constant
1429 -# Run multiple times the network (i.e. 10).
1430
1431If you are not using the graph API or the benchmark infrastructure you will need to manually pass a CLTuner object to CLScheduler before configuring any function.
1432
1433@code{.cpp}
1434CLTuner tuner;
1435
1436// Setup Scheduler
1437CLScheduler::get().default_init(&tuner);
1438@endcode
1439
1440After the first run, the CLTuner's results can be exported to a file using the method "save_to_file()".
1441- tuner.save_to_file("results.csv");
1442
1443This file can be also imported using the method "load_from_file("results.csv")".
1444- tuner.load_from_file("results.csv");
Anthony Barbier6ff3b192017-09-04 18:44:23 +01001445*/
Anthony Barbierd51ea0a2018-08-07 17:48:03 +01001446} // namespace arm_compute