Thank you for sending your enquiry! One of our team members will contact you shortly.
Thank you for sending your booking! One of our team members will contact you shortly.
Duration 28 hours
Course Outline
Introduction
- What is OpenCL?
- Comparison: OpenCL vs CUDA vs SYCL
- Overview of OpenCL features and architecture
- Setting up the Development Environment
Getting Started
- Creating a new OpenCL project in Visual Studio Code
- Exploring project structure and files
- Compiling and executing the program
- Displaying output using printf and fprintf
OpenCL API
- Understanding the role of the OpenCL API in host programs
- Using the OpenCL API to query device information and capabilities
- Using the OpenCL API to create contexts, command queues, buffers, kernels, and events
- Using the OpenCL API to enqueue commands such as read, write, copy, map, unmap, execute, and wait
- Using the OpenCL API to handle errors and exceptions
OpenCL C
- Understanding the role of OpenCL C in device programs
- Using OpenCL C to write kernels for device execution and data manipulation
- Using OpenCL C data types, qualifiers, operators, and expressions
- Using OpenCL C built-in functions, including math, geometric, and relational functions
- Using OpenCL C extensions and libraries, such as atomic, image, and cl_khr_fp16
OpenCL Memory Model
- Understanding the differences between host and device memory models
- Using OpenCL memory spaces: global, local, constant, and private
- Using OpenCL memory objects: buffers, images, and pipes
- Using OpenCL memory access modes: read-only, write-only, read-write, etc.
- Using OpenCL memory consistency models and synchronization mechanisms
OpenCL Execution Model
- Understanding the differences between host and device execution models
- Using OpenCL work-items, work-groups, and ND-ranges to define parallelism
- Using OpenCL work-item functions like get_global_id, get_local_id, and get_group_id
- Using OpenCL work-group functions like barrier, work_group_reduce, and work_group_scan
- Using OpenCL device functions like get_num_groups, get_global_size, and get_local_size
Debugging
- Understanding common errors and bugs in OpenCL programs
- Using the Visual Studio Code debugger to inspect variables, breakpoints, and call stacks
- Using CodeXL to debug and analyze OpenCL programs on AMD devices
- Using Intel VTune to debug and analyze OpenCL programs on Intel devices
- Using NVIDIA Nsight to debug and analyze OpenCL programs on NVIDIA devices
Optimization
- Understanding factors affecting OpenCL program performance
- Using OpenCL vector data types and vectorization techniques to boost arithmetic throughput
- Using OpenCL loop unrolling and tiling techniques to reduce control overhead and improve locality
- Using OpenCL local memory and functions to optimize memory access and bandwidth
- Using OpenCL profiling and tools to measure and enhance execution time and resource utilization
Requirements
- Familiarity with C/C++ language and parallel programming concepts
- Foundational knowledge of computer architecture and memory hierarchy
- Proficiency with command-line tools and code editors
Target Audience
- Developers seeking to learn how to utilize OpenCL for heterogeneous device programming and parallelism exploitation
- Developers aiming to write portable, scalable code compatible with various platforms and devices
- Programmers interested in exploring low-level aspects of heterogeneous programming to optimize code performance