| lol please no If you are using C++, and want to parallelize something, just add "std::execution::par" to your algorithms. Instead of writing "std::for_each(...)" just write "std::for_each(std::execution::par, ...)". That's it. It really is that simple. And with the right compilers you can just compile the code to run on FPGAS, GPUs, or whatever. For someone that knows C++, doing that is the lowest barrier of entry, and gets you most of the way there without having to learn "some other programming language" like OpenMP (or anything else). |
OpenMP is probably the easiest join/fork model of parallelism on any C++ system I've used. It doesn't always get the best utilization of your CPU cores, but it's really, really simple.
It's the best way to start IMO, far easier than std::thread, or switching to functional style for other libraries. Just write the same code as before but with a few #pragma omp statements here and there.