This extension adds OpenCL C/C++ language support to VS Code.
- Auto Completion of Built-in OpenCL Symbols
- Built-in OpenCL API Reference
- Code Snippets
- Kernel Diagnostics
- Kernel Formatting
- Offline Kernel Compilation
- OpenCL C/C++ Syntax Highlighting
- OpenCL Compute Kernel Support (
*.cl
,*.ocl
) - OpenCL Devices Information
Feature | Requirements |
---|---|
Kernel Diagnostics |
OpenCL Runtime [Intel, NVidia, AMD] |
OpenCL Devices Information |
OpenCL Runtime [Intel, NVidia, AMD] |
Offline Kernel Compilation |
Intel® SDK for OpenCL™ 2019 [Windows, Linux] or OpenCL.framework [macOS] (shipped with XCode) |
Kernel Formatting |
Formatting feature requires clang-format . By default, the extension searches for the utility inside ms-vscode.cpptools extension. |
Setting | Description |
---|---|
Kernel Diagnostics | |
OpenCL.server.enable |
Enables OpenCL Language Server. |
OpenCL.server.buildOptions |
Build options to be used for building the program. The list of supported build options. |
OpenCL.server.deviceID |
Device ID or 0 (automatic selection) of the OpenCL device to be used for diagnostics. Use the OpenCL: Select command or the OpenCL Devices explorer actions to specify the identifier. |
OpenCL.server.maxNumberOfProblems |
Controls the maximum number of problems produced by the server. |
opencl.trace.server |
Traces the communication between VS Code and the OpenCL language server. |
OpenCL Devices Information | |
OpenCL.explorer.localizedProperties |
Show localized properties of OpenCL devices in the explorer view (uncheck to show raw OpenCL properties). |
Kernel Formatting | |
OpenCL.formatting.name |
Default formatting utility is 'clang-format', which is shipped with ms-vscode.cpptools extension. Specify an absolute path to use another version of clang-format . |
Command | Description |
---|---|
OpenCL: Info |
This command opens a new VS Code tab filled with the information about available OpenCL devices |
OpenCL: Select |
Select the OpenCL device for kernel diagnostics |
OpenCL: Toggle View |
Toggle the explorer view (display localized or raw properties) |
This extension provides predefined set of VS Code tasks for kernel compilation using ioc32/ioc64
or openclc
(on macOS).
See TASKS.md for details.
See FAQ.md for known issues.
See development notes.
OpenCL is the trademark of Apple Inc.