# OpenCL

> open standard for programming heterogenous computing systems, such as CPUs or GPUs

**Wikidata**: [Q681360](https://www.wikidata.org/wiki/Q681360)  
**Wikipedia**: [English](https://en.wikipedia.org/wiki/OpenCL)  
**Source**: https://4ort.xyz/entity/opencl

## Summary

OpenCL is a software framework launched on 28 August 2009.

## Summary
OpenCL (Open Computing Language) is an open, royalty-free standard for writing programs that execute across heterogeneous computing platforms—CPUs, GPUs, DSPs, FPGAs and other processors—using a single C-based language. Created by Apple and now maintained by the Khronos Group, it lets developers write once and run their code on everything from a laptop’s integrated graphics to a data-center GPU.

## Key Facts
- **Inception**: 28 Aug 2009 (Apple submitted draft to Khronos Group)
- **Current stable version**: 3.0.19 (released 10 Jul 2025)
- **Maintainer**: Khronos Group (since 2009); originally created by Apple Inc.
- **License**: OSI-approved open-source license
- **Official website**: https://www.khronos.org/opencl
- **Supported platforms**: Microsoft Windows, macOS, Linux, FreeBSD, Android
- **Media type**: text/x-opencl-src (unofficial MIME type)
- **Wikidata sitelinks**: 28 language editions
- **Typing discipline**: nominative, manifest, weak, static
- **Logo**: OpenCL_logo.svg on Wikimedia Commons

## FAQs
### Q: What hardware can OpenCL programs run on?
A: Any device whose vendor ships an OpenCL runtime—common examples include AMD, Intel and NVIDIA GPUs, ARM Mali mobile GPUs, Apple Silicon, and x86/ARM CPUs.

### Q: Is OpenCL the same as OpenGL?
A: No. OpenGL is for graphics rendering; OpenCL is for general-purpose parallel compute. They are both Khronos standards but solve different problems.

### Q: Do I pay royalties to use OpenCL?
A: No. The specification is royalty-free and implementers may create and ship conformant implementations without licensing fees.

### Q: Which version should I target today?
A: OpenCL 3.0 is the latest stable generation; it unifies the feature set while letting vendors expose optional 2.x-class features, so targeting 3.0 maximizes portability.

## Why It Matters
Before OpenCL, developers who wanted to tap the raw floating-point power of a GPU had to write vendor-specific code—NVIDIA CUDA for GeForce, BrookGPU for ATI, or proprietary console libraries. OpenCL created the first cross-vendor, cross-platform framework that let a researcher, start-up, or game studio write a single kernel in standard C99 and watch it scale from a mobile phone to a workstation GPU. By commoditizing accelerator programming, OpenCL accelerated scientific breakthroughs (molecular dynamics, weather modeling, crypto-currency mining) and became the fallback path for GPU compute on Apple devices after Apple deprecated CUDA. Its open governance also guarantees that new hardware generations—whether RISC-V vector units or AI accelerators—can expose a uniform programming model without locking users into one silicon vendor.

## Notable For
- First open, royalty-free standard to unify CPUs, GPUs and other accelerators under one language
- Ships pre-installed on every macOS version since 10.6 Snow Leopard and on most Android Linux stacks
- Backed by a conformance test suite: implementations must pass ~20 000 tests to claim “OpenCL” trademark
- Version 3.0 retro-fits all 2.x optional features, letting vendors expose only what their hardware supports—ending the “version fragmentation” problem that plagued 1.2 vs 2.0 adoption

## Body
### Origins and Governance
Apple originally developed OpenCL for macOS Snow Leopard and transferred the draft specification to the Khronos Group on 28 Aug 2009. The Khronos Compute Working Group now evolves the standard, publishes the specification, and releases conformance tests.

### Technical Model
OpenCL separates host code (runs on the CPU) from kernels (runs on compute devices). A platform consists of one host plus any number of OpenCL devices; each device contains one or more compute units subdivided into processing elements. Memory regions are explicitly tiered—global, local, private, constant—mirroring physical GPU hierarchies.

### Version History
- 1.0 (Dec 2008) – first release
- 1.1 (Jun 2010) – adds 3-D work-groups
- 1.2 (Nov 2011) – device partitioning, enhanced images
- 2.0 (Nov 2013) – shared virtual memory, C11 atomics
- 2.1 (Mar 2016) – OpenCL C++ kernel language
- 2.2 (May 2017) – final C++ kernel version
- 3.0 (Sep 2020) – optional features, baseline OpenCL 1.2, latest patch 3.0.19 (Jul 2025)

### Platform Availability
Microsoft Windows drivers ship from AMD, Intel, NVIDIA; Apple bundles its own OpenCL.framework on macOS; Linux distributions package Mesa’s Clover, Intel’s Neo, AMD’s ROCm and NVIDIA’s proprietary driver. FreeBSD and Android inherit the Linux kernel driver model.

### Programming Details
Kernels are written in OpenCL C, a C99 subset with vector types, address-space qualifiers, and built-in work-item functions. The host API is C and C++; third-party bindings exist for Python, Rust, Go, Java and .NET. Compilation happens online: source is passed to the driver, compiled to the device ISA, and cached.

## Schema Markup
```json
{
  "@context": "https://schema.org",
  "@type": "Thing",
  "name": "OpenCL",
  "description": "Open, royalty-free standard for parallel programming of heterogeneous processors.",
  "url": "https://www.khronos.org/opencl",
  "sameAs": ["https://www.wikidata.org/wiki/Q13267", "https://en.wikipedia.org/wiki/OpenCL"],
  "additionalType": "SoftwareFramework"
}

## References

1. [Source](https://github.com/JohnMarkOckerbloom/ftl/blob/master/data/wikimap)
2. [The OpenCL Specification](https://registry.khronos.org/OpenCL/specs/3.0-unified/html/OpenCL_API.html)
3. [The OpenCL™ Specification](https://registry.khronos.org/OpenCL/specs/3.0-unified/html/OpenCL_API.html)
4. Freebase Data Dumps. 2013
5. [Source](https://gitlab.freedesktop.org/xdg/shared-mime-info/-/commit/4ab969c398671c519a10a601ad3eeb46f04361de)
6. Quora
7. National Library of Israel Names and Subjects Authority File