MatCL: A new easy-to use OpenCL toolbox for MathWorks Matlab

2018 
We present "MatCL" an OpenCL interface for MathWorks Matlab. This MEX-based toolbox aims at providing a simple and easy to use solution to launch OpenCL kernels and handle memory transfers from Matlab using a single command. In comparison to other Matlab OpenCL solutions, MatCL is not just an OpenCL API wrapper but encapsulates the low-level Host API calls necessary to initialize devices, create OpenCL buffers from Matlab workspace variables, build and launch kernels. It also supports queuing multiple kernels and OpenCL 2.x Pipes. MatCL is primarily intended to help in the development and testing of OpenCL kernels by allowing to transparently pass data from and to Matlab. This is especially helpful for kernels intended to be deployed on FPGAs or in an HPC environment. With these systems it can become necessary to test or benchmark using suitable input data or automatically verify results independent from the target architecture. Because MatCL handles the entire low-level process, this toolbox makes it possible to execute kernels without in depth knowledge of the Host API. This can reduce the OpenCL entry threshold significantly and thereby help make OpenCL more attractive to a wider user base. MatCL is also optimized to allow efficient execution of OpenCL kernels within Matlab to accelerate computationally intensive tasks without having to rely on Nvidia CUDA. This also allows Matlab to harness the power of heterogeneous computing, as OpenCL makes it possible to implement efficiently parallelized code, which runs on CPUs and GPUs. In addition to single command kernel execution, MatCL also allows for an independent two-step kernel compilation and launch workflow to save the kernel compile time and allow efficient repetitive kernel execution.
    • Correction
    • Source
    • Cite
    • Save
    • Machine Reading By IdeaReader
    0
    References
    1
    Citations
    NaN
    KQI
    []