On 08/19/2011 01:53 PM, David W Noon wrote:

The 2011 C++ standard does not, but GCC and a few other compilers offer
a facility called OpenMP that parallelises loops; it works for C, C++
and FORTRAN, at least within GCC.
I do know about OpenMP and I seem to remember that there is an article about same in the FPC Wiki.

A C++ extension might use some syntax-candy (like "parallel") to make OpenMP (hidden in a library) easily usable.

std::async(), std::future and std::promise seems to be provide some "sntax candy" for making threads more usable.

here in the FAQ they write:
"The *packaged_task* type is provided to simplify launching a thread to execute a task. In particular, it takes care of setting up a *future* connected to a *promise* and to provides the wrapper code to put the return value or exception from the task into the *promise*."

-Michael
_______________________________________________
fpc-devel maillist  -  fpc-devel@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-devel

Reply via email to