Book Description
Learn how to accelerate C++ programs using data parallelism. This open book enables C++ programmers to be at the forefront of this exciting and important new development that is helping to push computing to new levels. It is full of practical advice, detailed explanations, and code examples to illustrate key topics.
Data parallelism in C++ enables access to parallel resources in a modern heterogeneous system, freeing you from being locked into any particular computing device. Now a single C++ application can use any combination of devices - including GPUs, CPUs, FPGAs and AI ASICs - that are suitable to the problems at hand.
This book teaches data-parallel programming using C++ and the SYCL standard from the Khronos Group and walks through everything needed to use SYCL for programming heterogeneous systems. The book begins by introducing data parallelism and foundational topics for effective use of SYCL and Data Parallel C++ (DPC++), the open source compiler used in this book. Later chapters cover advanced topics including error handling, hardware-specific programming, communication and synchronization, and memory model considerations.
You will learn:
- How to accelerate C++ programs using data-parallel programming;
- How to target multiple device types (e.g. CPU, GPU, FPGA);
- How to use SYCL and SYCL compilers;
- How to connect with computing's heterogeneous future via Intel's oneAPI initiative.
This open book is licensed under a Creative Commons License (CC BY). You can download Data Parallel C++ ebook for free in PDF format (15.8 MB).
Table of Contents
Chapter 1
Introduction
Chapter 2
Where Code Executes
Chapter 3
Data Management
Chapter 4
Expressing Parallelism
Chapter 5
Error Handling
Chapter 6
Unified Shared Memory
Chapter 7
Buffers
Chapter 8
Scheduling Kernels and Data Movement
Chapter 9
Communication and Synchronization
Chapter 10
Defining Kernels
Chapter 11
Vectors
Chapter 12
Device Information
Chapter 13
Practical Tips
Chapter 14
Common Parallel Patterns
Chapter 15
Programming for GPUs
Chapter 16
Programming for CPUs
Chapter 17
Programming for FPGAs
Chapter 18
Libraries
Chapter 19
Memory Model and Atomics
Epilogue
Future Direction of DPC++