Introduction

The Foundry’s Blink is a framework which allows you to write code once and run it on any supported device. With Blink, your code can be run on the GPU, to take advantage of its massively parallel processing capabilities. Blink code can also be turned into SIMD instructions, where possible, to accelerate your code on the CPU. This is achieved through code translation, in which we take Blink code and turn it into specific code for each of the devices we target. Currently, the code in a Blink “kernel” can be turned into standard C++ for the CPU, SIMD code for the CPU, OpenCL code for the GPU or CUDA code for the GPU. Kernels are generated and compiled on-the-fly, allowing you to switch between devices at will.

Blink “kernels” are the cornerstone of our Blink framework. A Blink kernel is similar to a C++ class, but with some special parameter types and functions. When used for image processing, a Blink kernel can be thought of as a piece of code that describes what to do at each position in the output image in order to produce the output picture. In this user guide, we’ll take you through some simple kernels step-by-step and give you all the information you’ll need to start writing your own.

Requirements

For GPU acceleration:

  • An AMD GPU able to run OpenCL 1.1 and above.

or * An NVIDIA GPU with compute capability 3.0 or above. * NVIDIA drivers with CUDA 11.1 Update 1 or above on Windows or Linux (Driver versions 456.81 (Windows) and 455.32 (Linux) or above are required).