[Development] Notes from "C++17 language and std library features for Qt 6"
Allan Sandfeld Jensen
kde at carewolf.com
Wed Nov 20 20:43:31 CET 2019
On Wednesday, 20 November 2019 20:20:29 CET Kari Oikarinen wrote:
> ## Parallel STL algorithms
> We could allow parallel execution tags in our API to let users ask for
> use of parallel algorithms.
> But what are the places in Qt API that actually need these? More data
> analysis stuff (if developed) would find it helpful. But often users
> get to choose their own algorithms and so can use parallel algorithms
> without our containers needing to know about it.
> If a parallel STL implementation is not available, falling back to
> single-threaded implementation is always an option. So support could
> be utilized only when available and not demanded from all platforms.
> Or the platfrom support can be a shim that still always processes
> everything without parallelism.
One problem with this is that it is a very recent addition in the standard
libraries, and isn't even in any released version of libc++ yet. So using it
would require MSVC 2019 and gcc 9, and a future version of clang.
It could be useful for image handling though, and theoretically also for
raster painting if for some reason the GPU isn't used.
It could be opportunistically used when available though. It would be entirely
internal, and just split some operations over multiple threads. But the things
it would optimize are operations that would be even faster if done on the GPU
More information about the Development