Free Software Foundation!

Join now


From Free Software Directory
Jump to: navigation,

C Framework for OpenCL

The C Framework for OpenCL, cf4ocl, is a cross-platform pure C object-oriented framework for developing and benchmarking OpenCL projects. It aims to:

  • Promote the rapid development of OpenCL host programs in C (with support for C++) and avoid the tedious and error-prone boilerplate code usually required.
  • Assist in the benchmarking of OpenCL events, such as kernel execution and data transfers. Profiling comes for free with cf4ocl.
  • Simplify the analysis of the OpenCL environment and of kernel requirements.
  • Allow for all levels of integration with existing OpenCL code: use as much or as few of cf4ocl required for your project, with full access to the underlying OpenCL objects and functions at all times.


  • Object-oriented interface to the OpenCL API
 * New/destroy functions, no direct memory alloc/free
 * Easy (and extensible) device selection
 * Simple event dependency mechanism
 * User-friendly error management
  • OpenCL version and platform independent
  • Integrated profiling
  • Advanced device query utility
  • Offline kernel compiler and linker


Documentation can be generated with Doxygen in HTML, Latex, PDF and man pages format. Latest HTML documentation.

Extension or Plugin

This package can be used as an extension, plugin, or add-on to:


LicenseVerified byVerified onNotes
LGPLv3orlaterJgay17 October 2014
Library code
GPLv3orlaterJgay17 October 2014
Remaining code

Leaders and contributors

Nuno Fachada Author

Resources and communication

Software prerequisites

Kind Description
Required to build GLib 2.32+
Required to use OpenCL 1.0
Required to build OpenCL 1.0
Required to use GLib 2.32+

This entry (in part or in whole) was last reviewed on 5 July 2016.


Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.3 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license is included in the page “GNU Free Documentation License”.

The copyright and license notices on this page only apply to the text on this page. Any software or copyright-licenses or other similar notices described in this text has its own copyright notice and license, which can usually be found in the distribution or license text itself.

Personal tools