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
- Defining OpenCL
- Comparing OpenCL with CUDA and SYCL
- Overview of OpenCL features and architectural components
- Configuring the Development Environment
Getting Started
- Initializing a new OpenCL project in Visual Studio Code
- Examining the project structure and file organization
- Compiling and executing the application
- Displaying output using printf and fprintf functions
OpenCL API
- Understanding the role of the OpenCL API within the host program
- Using the OpenCL API to retrieve device information and capabilities
- Creating contexts, command queues, buffers, kernels, and events via the OpenCL API
- Enqueueing commands such as read, write, copy, map, unmap, execute, and wait
- Handling errors and exceptions using the OpenCL API
OpenCL C
- Understanding the role of OpenCL C in device-side programming
- Writing kernels in OpenCL C to execute on the device and manipulate data
- Utilizing OpenCL C data types, qualifiers, operators, and expressions
- Applying OpenCL C built-in functions for math, geometry, and relations
- Working with OpenCL C extensions and libraries, including atomic operations and image processing
OpenCL Memory Model
- Distinguishing between host and device memory models
- Working with OpenCL memory spaces: global, local, constant, and private
- Managing OpenCL memory objects such as buffers, images, and pipes
- Applying OpenCL memory access modes like read-only, write-only, and read-write
- Understanding the OpenCL memory consistency model and synchronization techniques
OpenCL Execution Model
- Distinguishing between host and device execution models
- Defining parallelism using OpenCL work-items, work-groups, and ND-ranges
- Using OpenCL work-item functions like get_global_id, get_local_id, and get_group_id
- Applying OpenCL work-group functions such as barrier, work_group_reduce, and work_group_scan
- Utilizing OpenCL device functions like get_num_groups, get_global_size, and get_local_size
Debugging
- Identifying common errors and bugs in OpenCL applications
- Using the Visual Studio Code debugger to inspect variables, breakpoints, and call stacks
- Debugging and analyzing OpenCL programs on AMD devices with CodeXL
- Debugging and analyzing OpenCL programs on Intel devices with Intel VTune
- Debugging and analyzing OpenCL programs on NVIDIA devices with NVIDIA Nsight
Optimization
- Analyzing factors that impact OpenCL program performance
- Enhancing arithmetic throughput using OpenCL vector data types and vectorization techniques
- Reducing control overhead and improving locality through OpenCL loop unrolling and tiling
- Optimizing memory access and bandwidth using OpenCL local memory and associated functions
- Measuring and improving execution time and resource utilization using OpenCL profiling tools
Requirements
- Familiarity with C/C++ programming and the principles of parallel processing
- Fundamental knowledge of computer architecture and memory hierarchy
- Practical experience with command-line utilities and code editors
Target Audience
- Developers seeking to harness OpenCL for programming heterogeneous devices and exploiting their parallel power
- Engineers aiming to develop portable, scalable code compatible with multiple platforms and devices
- Programmers interested in exploring the low-level intricacies of heterogeneous computing to enhance code performance