aboutsummaryrefslogtreecommitdiff
path: root/compute_kernel_writer/README.md
diff options
context:
space:
mode:
Diffstat (limited to 'compute_kernel_writer/README.md')
-rw-r--r--compute_kernel_writer/README.md32
1 files changed, 21 insertions, 11 deletions
diff --git a/compute_kernel_writer/README.md b/compute_kernel_writer/README.md
index 9a920b7882..2c7636ca9f 100644
--- a/compute_kernel_writer/README.md
+++ b/compute_kernel_writer/README.md
@@ -2,7 +2,7 @@
Compute Kernel Writer is a tile-based, just-in-time code writer for deep learning and computer vision applications.
This tool offers a C++ interface to allow developers to write functions without a return type (called "kernels")
-using their preferred programming language (at the moment, only OpenCL is supported).
+using their preferred programming language (at the moment, only OpenCL is supported).
The library is specifically designed to be lightweight and to offer an intuitive API for efficient code writing.
## Getting started
@@ -12,7 +12,8 @@ The following subsections show you how to do this.
### Dependencies
-This project requires the following dependencies, obtainable via your preferred package manager, to be installed and available on your system.
+This project requires the following dependencies, obtainable via your preferred package manager, to be installed and
+available on your system.
* `build-essential`
* `cmake >= 3.14`
@@ -20,8 +21,10 @@ This project requires the following dependencies, obtainable via your preferred
In addition, the guide makes use of the following toolchains:
-* (Optional) `Arm GNU toolchain` available to download from the [Arm Developer](https://developer.arm.com/downloads/-/arm-gnu-toolchain-downloads) website
-* (Optional) `Android NDK toolset` available to download from the [Android Developer](https://developer.android.com/ndk/downloads/index.html) website
+* (Optional) `Arm GNU toolchain` available to download from
+ the [Arm Developer](https://developer.arm.com/downloads/-/arm-gnu-toolchain-downloads) website
+* (Optional) `Android NDK toolset` available to download from
+ the [Android Developer](https://developer.android.com/ndk/downloads/index.html) website
### Building and running tests
@@ -35,13 +38,16 @@ CXX=g++ cmake -G Ninja -DBUILD_SHARED_LIBS=ON -DCMAKE_BUILD_TYPE=Release -DCKW_E
cmake --build .
```
-The preceding commands build the library in release mode (`-DCMAKE_BUILD_TYPE=Release`) and targets OpenCL code generation (`-DCKW_ENABLE_OPENCL=ON`).
-In addition, code assertions are enabled (`-DCKW_ENABLE_ASSERTS=ON`) and the test suite is built (`-DCKW_BUILD_TESTING=ON`).
+The preceding commands build the library in release mode (`-DCMAKE_BUILD_TYPE=Release`) and targets OpenCL code
+generation (`-DCKW_ENABLE_OPENCL=ON`).
+In addition, code assertions are enabled (`-DCKW_ENABLE_ASSERTS=ON`) and the test suite is
+built (`-DCKW_BUILD_TESTING=ON`).
Alternatively, choose to build a static instead of a shared library by setting `-DBUILD_SHARED_LIBS=OFF`.
#### Cross-compile to Linux AArch64
-The Arm GNU toolchain can be used to cross-compile the project to a Linux system with an AArch64 processor, like a Raspberry Pi, using an x86_64 Linux host machine.
+The Arm GNU toolchain can be used to cross-compile the project to a Linux system with an AArch64 processor, like a
+Raspberry Pi, using an x86_64 Linux host machine.
```shell
mkdir -p build && cd build
@@ -49,11 +55,13 @@ CXX=aarch64-none-linux-gnu-g++ cmake -G Ninja -DBUILD_SHARED_LIBS=ON -DCMAKE_BUI
cmake --build .
```
-The build configuration is identical to the previous step but now requires specifying the target triple in the CXX compiler (`CXX=aarch64-none-linux-gnu-g++`) to generate binaries for the target platform.
+The build configuration is identical to the previous step but now requires specifying the target triple in the CXX
+compiler (`CXX=aarch64-none-linux-gnu-g++`) to generate binaries for the target platform.
#### Cross-compile to Android AArch64
-Cross-compiling for Android systems requires the Android NDK toolset. The downloaded NDK contains the toolchain file necessary for cross-compiling the project.
+Cross-compiling for Android systems requires the Android NDK toolset. The downloaded NDK contains the toolchain file
+necessary for cross-compiling the project.
```shell
mkdir -p build && cd build
@@ -61,7 +69,8 @@ cmake -G Ninja -DBUILD_SHARED_LIBS=ON -DCMAKE_BUILD_TYPE=Release -DCKW_ENABLE_OP
cmake --build .
```
-This build re-uses the same build configuration as before, but this time does not require specifying the CXX compiler as this (and other target-specific information) is handled by the toolchain file (`-DCMAKE_TOOLCHAIN_FILE`).
+This build re-uses the same build configuration as before, but this time does not require specifying the CXX compiler as
+this (and other target-specific information) is handled by the toolchain file (`-DCMAKE_TOOLCHAIN_FILE`).
#### Run the validation test suite
@@ -73,7 +82,8 @@ Confirm the project has been built successfully by running the validation test s
### List of build options
-This project can be configured with the following build options. Enable options by passing them to the CMake command, preceded with `-D`.
+This project can be configured with the following build options. Enable options by passing them to the CMake command,
+preceded with `-D`.
| Option | Description |
|:---------------------|:------------------------------------------------------------------------------------------------------------------------------------------|