Skip to content

Commit

Permalink
Compute Library v22.11
Browse files Browse the repository at this point in the history
  • Loading branch information
Jenkins committed Nov 18, 2022
1 parent aabef6c commit 1b3192e
Show file tree
Hide file tree
Showing 227 changed files with 12,775 additions and 3,223 deletions.
20 changes: 20 additions & 0 deletions Android.bp
Expand Up @@ -447,6 +447,7 @@ cc_library_static {
"src/cpu/kernels/CpuWinogradConv2dKernel.cpp",
"src/cpu/kernels/activation/generic/neon/fp16.cpp",
"src/cpu/kernels/activation/generic/neon/fp32.cpp",
"src/cpu/kernels/activation/generic/neon/lut.cpp",
"src/cpu/kernels/activation/generic/neon/qasymm8.cpp",
"src/cpu/kernels/activation/generic/neon/qasymm8_signed.cpp",
"src/cpu/kernels/activation/generic/neon/qsymm16.cpp",
Expand Down Expand Up @@ -519,6 +520,7 @@ cc_library_static {
"src/cpu/kernels/meanstddevnorm/generic/neon/fp16.cpp",
"src/cpu/kernels/meanstddevnorm/generic/neon/fp32.cpp",
"src/cpu/kernels/meanstddevnorm/generic/neon/impl.cpp",
"src/cpu/kernels/meanstddevnorm/generic/neon/qasymm8.cpp",
"src/cpu/kernels/pool2d/neon/fp16.cpp",
"src/cpu/kernels/pool2d/neon/fp32.cpp",
"src/cpu/kernels/pool2d/neon/nchw/all.cpp",
Expand Down Expand Up @@ -590,6 +592,24 @@ cc_library_static {
"src/cpu/operators/CpuTranspose.cpp",
"src/cpu/operators/CpuWinogradConv2d.cpp",
"src/cpu/operators/internal/CpuGemmAssemblyDispatch.cpp",
"src/dynamic_fusion/runtime/gpu/cl/ClKernelRuntime.cpp",
"src/dynamic_fusion/runtime/gpu/cl/ClWorkloadRuntime.cpp",
"src/dynamic_fusion/sketch/OperatorAttributes.cpp",
"src/dynamic_fusion/sketch/gpu/GpuKernelArgument.cpp",
"src/dynamic_fusion/sketch/gpu/GpuKernelComponentGraph.cpp",
"src/dynamic_fusion/sketch/gpu/GpuKernelComponentGroup.cpp",
"src/dynamic_fusion/sketch/gpu/GpuKernelComponentStream.cpp",
"src/dynamic_fusion/sketch/gpu/GpuLogicalKernel.cpp",
"src/dynamic_fusion/sketch/gpu/GpuOperatorGroup.cpp",
"src/dynamic_fusion/sketch/gpu/GpuWorkloadContext.cpp",
"src/dynamic_fusion/sketch/gpu/GpuWorkloadSketch.cpp",
"src/dynamic_fusion/sketch/gpu/components/cl/ClComponentDirectConv2d.cpp",
"src/dynamic_fusion/sketch/gpu/components/cl/ClComponentStore.cpp",
"src/dynamic_fusion/sketch/gpu/operators/GpuConv2d.cpp",
"src/dynamic_fusion/sketch/gpu/template_writer/GpuKernelVariableTable.cpp",
"src/dynamic_fusion/sketch/gpu/template_writer/cl/ClTemplateDirectConv2d.cpp",
"src/dynamic_fusion/sketch/gpu/template_writer/cl/ClTemplateStore.cpp",
"src/dynamic_fusion/sketch/gpu/template_writer/cl/ClTemplateWriter.cpp",
"src/gpu/cl/ClContext.cpp",
"src/gpu/cl/ClKernelLibrary.cpp",
"src/gpu/cl/ClQueue.cpp",
Expand Down
41 changes: 21 additions & 20 deletions README.md
Expand Up @@ -10,7 +10,7 @@
<img src="https://raw.githubusercontent.com/ARM-software/ComputeLibrary/gh-pages/ACL_logo.png"/><br><br>
</div>

# Compute Library ![](https://img.shields.io/badge/latest_release-22.08-green)
# Compute Library ![](https://img.shields.io/badge/latest_release-22.11-green)


The Compute Library is a collection of low-level machine learning functions optimized for Arm® Cortex®-A, Arm® Neoverse® and Arm® Mali™ GPUs architectures.<br>
Expand All @@ -30,15 +30,15 @@ Key Features:

<br>

| Repository | Link |
| ----------- | ----------- |
| Release | https://github.com/arm-software/ComputeLibrary |
| Development | https://review.mlplatform.org/#/admin/projects/ml/ComputeLibrary |
| Repository | Link |
| ----------- | ---------------------------------------------------------------- |
| Release | https://github.com/arm-software/ComputeLibrary |
| Development | https://review.mlplatform.org/#/admin/projects/ml/ComputeLibrary |

<br>

## Documentation
[![Documentation](https://img.shields.io/badge/documentation-22.08-green)](https://arm-software.github.io/ComputeLibrary/latest)
[![Documentation](https://img.shields.io/badge/documentation-22.11-green)](https://arm-software.github.io/ComputeLibrary/latest)

> Note: The documentation includes the reference API, changelogs, build guide, contribution guide, errata, etc.
Expand All @@ -49,25 +49,26 @@ All the binaries can be downloaded from [here](https://github.com/ARM-software/C

<br>

| Platform | Operating System | Release archive (Download) |
| ----------- | ----------- | ----------- |
| Raspberry Pi 4 | Linux 32bit | [![](https://img.shields.io/badge/build-neon-orange)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.08/arm_compute-v22.08-bin-linux-armv7a-neon.tar.gz) |
| Raspberry Pi 4 | Linux 64bit | [![](https://img.shields.io/badge/build-neon-orange)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.08/arm_compute-v22.08-bin-linux-arm64-v8a-neon.tar.gz) |
| Odroid N2 | Linux 64bit | [![](https://img.shields.io/badge/build-neon-orange)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.08/arm_compute-v22.08-bin-linux-arm64-v8a-neon.tar.gz) [![](https://img.shields.io/badge/build-opencl-blue)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.08/arm_compute-v22.08-bin-linux-arm64-v8a-cl.tar.gz) [![](https://img.shields.io/badge/build-neon+cl-yellowgreen)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.08/arm_compute-v22.08-bin-linux-arm64-v8a-neon-cl.tar.gz) |
| HiKey960 | Linux 64bit | [![](https://img.shields.io/badge/build-neon-orange)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.08/arm_compute-v22.08-bin-linux-arm64-v8a-neon.tar.gz) [![](https://img.shields.io/badge/build-opencl-blue)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.08/arm_compute-v22.08-bin-linux-arm64-v8a-cl.tar.gz) [![](https://img.shields.io/badge/build-neon+cl-yellowgreen)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.08/arm_compute-v22.08-bin-linux-arm64-v8a-neon-cl.tar.gz) |
| Platform | Operating System | Release archive (Download) |
| -------------- | ---------------- | -------------------------- |
| Raspberry Pi 4 | Linux 32bit | [![](https://img.shields.io/badge/build-neon-orange)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.11/arm_compute-v22.11-bin-linux-armv7a-neon.tar.gz) |
| Raspberry Pi 4 | Linux 64bit | [![](https://img.shields.io/badge/build-neon-orange)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.11/arm_compute-v22.11-bin-linux-arm64-v8a-neon.tar.gz) |
| Odroid N2 | Linux 64bit | [![](https://img.shields.io/badge/build-neon-orange)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.11/arm_compute-v22.11-bin-linux-arm64-v8a-neon.tar.gz) [![](https://img.shields.io/badge/build-opencl-blue)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.11/arm_compute-v22.11-bin-linux-arm64-v8a-cl.tar.gz) [![](https://img.shields.io/badge/build-neon+cl-yellowgreen)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.11/arm_compute-v22.11-bin-linux-arm64-v8a-neon-cl.tar.gz) |
| HiKey960 | Linux 64bit | [![](https://img.shields.io/badge/build-neon-orange)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.11/arm_compute-v22.11-bin-linux-arm64-v8a-neon.tar.gz) [![](https://img.shields.io/badge/build-opencl-blue)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.11/arm_compute-v22.11-bin-linux-arm64-v8a-cl.tar.gz) [![](https://img.shields.io/badge/build-neon+cl-yellowgreen)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.11/arm_compute-v22.11-bin-linux-arm64-v8a-neon-cl.tar.gz) |

<br>

| Architecture | Operating System | Release archive (Download) |
| ----------- | ----------- | ----------- |
| armv7 | Linux | [![](https://img.shields.io/badge/build-neon-orange)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.08/arm_compute-v22.08-bin-linux-armv7a-neon.tar.gz) [![](https://img.shields.io/badge/build-opencl-blue)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.08/arm_compute-v22.08-bin-linux-armv7a-cl.tar.gz) [![](https://img.shields.io/badge/build-neon+cl-yellowgreen)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.08/arm_compute-v22.08-bin-linux-armv7a-neon-cl.tar.gz) |
| arm64-v8a | Android | [![](https://img.shields.io/badge/build-neon-orange)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.08/arm_compute-v22.08-bin-android-arm64-v8a-neon.tar.gz) [![](https://img.shields.io/badge/build-opencl-blue)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.08/arm_compute-v22.08-bin-android-arm64-v8a-cl.tar.gz) [![](https://img.shields.io/badge/build-neon+cl-yellowgreen)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.08/arm_compute-v22.08-bin-android-arm64-v8a-neon-cl.tar.gz) |
| arm64-v8a | Linux | [![](https://img.shields.io/badge/build-neon-orange)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.08/arm_compute-v22.08-bin-linux-arm64-v8a-neon.tar.gz) [![](https://img.shields.io/badge/build-opencl-blue)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.08/arm_compute-v22.08-bin-linux-arm64-v8a-cl.tar.gz) [![](https://img.shields.io/badge/build-neon+cl-yellowgreen)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.08/arm_compute-v22.08-bin-linux-arm64-v8a-neon-cl.tar.gz) |
| arm64-v8.2-a | Android | [![](https://img.shields.io/badge/build-neon-orange)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.08/arm_compute-v22.08-bin-android-arm64-v8.2-a-neon.tar.gz) [![](https://img.shields.io/badge/build-opencl-blue)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.08/arm_compute-v22.08-bin-android-arm64-v8.2-a-cl.tar.gz) [![](https://img.shields.io/badge/build-neon+cl-yellowgreen)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.08/arm_compute-v22.08-bin-android-arm64-v8.2-a-neon-cl.tar.gz) |
| arm64-v8.2-a | Linux | [![](https://img.shields.io/badge/build-neon-orange)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.08/arm_compute-v22.08-bin-linux-arm64-v8.2-a-neon.tar.gz) [![](https://img.shields.io/badge/build-opencl-blue)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.08/arm_compute-v22.08-bin-linux-arm64-v8.2-a-cl.tar.gz) [![](https://img.shields.io/badge/build-neon+cl-yellowgreen)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.08/arm_compute-v22.08-bin-linux-arm64-v8.2-a-neon-cl.tar.gz) |
| Architecture | Operating System | Release archive (Download) |
| ------------ | ---------------- | -------------------------- |
| armv7 | Linux | [![](https://img.shields.io/badge/build-neon-orange)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.11/arm_compute-v22.11-bin-linux-armv7a-neon.tar.gz) [![](https://img.shields.io/badge/build-opencl-blue)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.11/arm_compute-v22.11-bin-linux-armv7a-cl.tar.gz) [![](https://img.shields.io/badge/build-neon+cl-yellowgreen)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.11/arm_compute-v22.11-bin-linux-armv7a-neon-cl.tar.gz) |
| arm64-v8a | Android | [![](https://img.shields.io/badge/build-neon-orange)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.11/arm_compute-v22.11-bin-android-arm64-v8a-neon.tar.gz) [![](https://img.shields.io/badge/build-opencl-blue)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.11/arm_compute-v22.11-bin-android-arm64-v8a-cl.tar.gz) [![](https://img.shields.io/badge/build-neon+cl-yellowgreen)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.11/arm_compute-v22.11-bin-android-arm64-v8a-neon-cl.tar.gz) |
| arm64-v8a | Linux | [![](https://img.shields.io/badge/build-neon-orange)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.11/arm_compute-v22.11-bin-linux-arm64-v8a-neon.tar.gz) [![](https://img.shields.io/badge/build-opencl-blue)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.11/arm_compute-v22.11-bin-linux-arm64-v8a-cl.tar.gz) [![](https://img.shields.io/badge/build-neon+cl-yellowgreen)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.11/arm_compute-v22.11-bin-linux-arm64-v8a-neon-cl.tar.gz) |
| arm64-v8.2-a | Android | [![](https://img.shields.io/badge/build-neon-orange)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.11/arm_compute-v22.11-bin-android-arm64-v8.2-a-neon.tar.gz) [![](https://img.shields.io/badge/build-opencl-blue)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.11/arm_compute-v22.11-bin-android-arm64-v8.2-a-cl.tar.gz) [![](https://img.shields.io/badge/build-neon+cl-yellowgreen)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.11/arm_compute-v22.11-bin-android-arm64-v8.2-a-neon-cl.tar.gz) |
| arm64-v8.2-a | Linux | [![](https://img.shields.io/badge/build-neon-orange)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.11/arm_compute-v22.11-bin-linux-arm64-v8.2-a-neon.tar.gz) [![](https://img.shields.io/badge/build-opencl-blue)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.11/arm_compute-v22.11-bin-linux-arm64-v8.2-a-cl.tar.gz) [![](https://img.shields.io/badge/build-neon+cl-yellowgreen)](https://github.com/ARM-software/ComputeLibrary/releases/download/v22.11/arm_compute-v22.11-bin-linux-arm64-v8.2-a-neon-cl.tar.gz) |

<br>
Please refer to the following link for more pre-built binaries: [![](https://img.shields.io/badge/v22.08-bins-yellowgreen)](https://github.com/ARM-software/ComputeLibrary/releases/tag/v22.08)

Please refer to the following link for more pre-built binaries: [![](https://img.shields.io/badge/v22.11-bins-yellowgreen)](https://github.com/ARM-software/ComputeLibrary/releases/tag/v22.11)

Pre-build binaries are generated with the following security / good coding practices related flags:
> -Wall, -Wextra, -Wformat=2, -Winit-self, -Wstrict-overflow=2, -Wswitch-default, -Woverloaded-virtual, -Wformat-security, -Wctor-dtor-privacy, -Wsign-promo, -Weffc++, -pedantic, -fstack-protector-strong
Expand Down
10 changes: 8 additions & 2 deletions SConscript
Expand Up @@ -31,8 +31,8 @@ import zlib
import json
import codecs

VERSION = "v22.08"
LIBRARY_VERSION_MAJOR = 28
VERSION = "v22.11"
LIBRARY_VERSION_MAJOR = 29
LIBRARY_VERSION_MINOR = 0
LIBRARY_VERSION_PATCH = 0
SONAME_VERSION = str(LIBRARY_VERSION_MAJOR) + "." + str(LIBRARY_VERSION_MINOR) + "." + str(LIBRARY_VERSION_PATCH)
Expand Down Expand Up @@ -124,6 +124,12 @@ def build_library(name, build_env, sources, static=False, libs=[]):
else:
obj = cloned_build_env.SharedLibrary(name, source=sources, LIBS = arm_compute_env["LIBS"] + libs)

if env['mapfile']:
if not 'windows' in env['os'] and not 'macos' in env['os']:
cloned_build_env['LINKFLAGS'].append('"-Wl,-Map='+ name + '.map"')
else:
cloned_build_env['LINKFLAGS'].append('-Wl,-map,' + name + '.map')

obj = install_lib(obj)
build_env.Default(obj)
return obj
Expand Down
3 changes: 2 additions & 1 deletion SConstruct
Expand Up @@ -127,6 +127,7 @@ vars.AddVariables(
    └── Neon\n""", "", PathVariable.PathAccept),
BoolVariable("experimental_dynamic_fusion", "Build the experimental dynamic fusion files", False),
BoolVariable("experimental_fixed_format_kernels", "Enable fixed format kernels for GEMM", False),
BoolVariable("mapfile", "Generate a map file", False),
ListVariable("custom_options", "Custom options that can be used to turn on/off features", "none", ["disable_mmla_fp"]),
ListVariable("data_type_support", "Enable a list of data types to support", "all", ["qasymm8", "qasymm8_signed", "qsymm16", "fp16", "fp32", "integer"]),
ListVariable("data_layout_support", "Enable a list of data layout to support", "all", ["nhwc", "nchw"]),
Expand Down Expand Up @@ -312,7 +313,7 @@ else: # NONE "multi_isa" builds
elif 'armv8.6-a-sve' == env['arch']:
env.Append(CXXFLAGS = ['-march=armv8.6-a+sve'])
elif 'armv8.6-a' == env['arch']:
env.Append(CXXFLAGS = ['-march=armv8.6-a'])
env.Append(CXXFLAGS = ['-march=armv8.6-a+fp16'])

env.Append(CPPDEFINES = ['ARM_COMPUTE_ENABLE_I8MM', 'ARM_COMPUTE_ENABLE_BF16','ARM_COMPUTE_ENABLE_FP16'])
if "disable_mmla_fp" not in env['custom_options']:
Expand Down
12 changes: 12 additions & 0 deletions arm_compute/core/CL/CLCompileContext.h
Expand Up @@ -304,6 +304,18 @@ class CLCompileContext final
*/
bool is_wbsm_supported() const;

/** Return the DDK version. If the DDK version cannot be detected, return -1.
*
* @return The DDK version.
*/
int32_t get_ddk_version() const;

/** Return the Gpu target of the associated device
*
* @return GPUTarget
*/
GPUTarget get_gpu_target() const;

private:
/** Load program and its dependencies.
*
Expand Down
8 changes: 4 additions & 4 deletions arm_compute/core/CL/CLHelpers.h
Expand Up @@ -242,13 +242,13 @@ bool get_wbsm_support_info(const cl::Device &device);
*/
void set_wbsm(cl::Kernel &kernel, cl_int wbsm_hint);

/* Helper function to check if we can export the weights to cl_image
/* Helper function to check if we can export the tensor to cl_image
*
* @param[in] tensor Weights tensor
* @param[in] input tensor
*
* @return true if we can export the weights to cl_image
* @return true if we can export the tensor to cl_image
*/
bool export_weights_to_cl_image(const ITensorInfo *tensor);
bool export_to_cl_image(const ITensorInfo *tensor);

/* Helper function to force unroll with pragma when any of the input values (iterations) are greater than @ref max_manual_loop_unrolling
*
Expand Down
22 changes: 20 additions & 2 deletions arm_compute/core/ITensorInfo.h
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2016-2021 Arm Limited.
* Copyright (c) 2016-2022 Arm Limited.
*
* SPDX-License-Identifier: MIT
*
Expand Down Expand Up @@ -41,6 +41,11 @@ class ITensorInfo : public misc::ICloneable<ITensorInfo>
{
public:
using TensorDimsState = std::vector<int>;
/** An id that uniquely identifies an ITensorInfo within some domain (e.g. a workload)
*/
using Id = int32_t;
/** An invalid tensor id within a domain */
static constexpr Id invalid_tensor_id = -1;
/** Get the value representing dynamic dimension state
*
* @return Value representing dynamic dimension state
Expand Down Expand Up @@ -280,7 +285,20 @@ class ITensorInfo : public misc::ICloneable<ITensorInfo>
* @return A DataLayout containing the layout data information.
*/
virtual DataLayout data_layout() const = 0;

/** Get the workload tensor id of the tensor.
*
* @return Workload tensor id of the tensor
*/
virtual Id id() const = 0;
/** Set the tensor id
*/
virtual ITensorInfo &set_id(ITensorInfo::Id id) = 0;
/** Check if the tensor id is valid
*/
bool has_valid_id() const
{
return id() != invalid_tensor_id;
}
/** If infos are broadcast compatible tensor info's, return the broadcasted shape and the intersection of
* the broadcasted valid regions of the tensors.
*
Expand Down
1 change: 1 addition & 0 deletions arm_compute/core/KernelDescriptors.h
Expand Up @@ -106,6 +106,7 @@ struct DWCComputeKernelInfo
{
unsigned int n0{ 0 }; /**< Number of columns processed by each thread */
unsigned int m0{ 0 }; /**< Number of rows processed by each thread */
bool export_input_to_cl_image{ false }; /**< Export input to cl_image */
bool export_weights_to_cl_image{ false }; /**< Export the weights to cl_image */
};

Expand Down

0 comments on commit 1b3192e

Please sign in to comment.