Sequential, parallel, or parallel execution with vectorisation
Explore C++17 execution policies that enable running algorithms sequentially, in parallel, or with vectorization using SIMD. Understand how these approaches leverage CPU, compiler, and optimization features to improve algorithm efficiency.
We'll cover the following...
We'll cover the following...
By using an execution policy in C++17, you can specify whether the algorithm should run sequentially, in parallel, or in parallel with vectorization.
Execution Policies
The policy tag specifies whether an algorithm should run sequentially, in parallel, or in parallel with vectorization.
-
std::execution::seq: runs the algorithm sequentially -
std::execution::par: runs the algorithm in parallel on multiple threads -
std::execution::par_unseq...