[PATCH][libstdc++-v3 parallel mode] PR 33893 work correctly even if omp_get_dynamic()

Johannes Singler singler@ira.uka.de
Wed Nov 21 16:23:00 GMT 2007


Major revision of the parallel mode algorithms, to work correctly even
if omp_get_dynamic(), PR 33893.
Also, the quicksort variants work correctly if !omp_get_nested().
However, the speedup is limited to 2 in this case. Getting rid of this
limitation is very elaborate since OpenMP 2.5 does not support barriers
among a subset of a team. Maybe things get better with OpenMP 3.0, I
still have to look into this.

Because the process included a lot of formatting cleanup, I'm also
attaching a version of the patch ignoring white space, for better
readability.

Please comment and/or approve.

tested x86_64-unknown-linux-gnu: no regressions

2007-11-16  Johannes Singler  <singler@ira.uka.de>

       *include/parallel/multiway_merge.h: made omp_dynamic-safe
       *include/parallel/workstealing.h: made omp_dynamic-safe
       *include/parallel/base.h: infrastructure, cleanup
       *include/parallel/par_loop.h: made omp_dynamic-safe
       *include/parallel/features.h: activate loser tree variant
       *include/parallel/quicksort.h: made omp_dynamic-safe
       *include/parallel/compiletime_settings.h: settings overridable
       *include/parallel/equally_split.h: made omp_dynamic-safe
       *include/parallel/omp_loop_static.h: made omp_dynamic-safe
       *include/parallel/random_shuffle.h: made omp_dynamic-safe
       *include/parallel/balanced_quicksort.h: made omp_dynamic-safe
       *include/parallel/set_operations.h: made omp_dynamic-safe
       *include/parallel/unique_copy.h: made omp_dynamic-safe
       *include/parallel/multiway_mergesort.h: made omp_dynamic-safe
       *include/parallel/search.h: made omp_dynamic-safe
       *include/parallel/partition.h: made omp_dynamic-safe
       *include/parallel/partial_sum.h: made omp_dynamic-safe
       *include/parallel/find.h: made omp_dynamic-safe
       *include/parallel/omp_loop.h: made omp_dynamic-safe

Johannes



-------------- next part --------------
A non-text attachment was scrubbed...
Name: omp_set_dynamic_compatibility_and_cleanup.patch
Type: text/x-patch
Size: 135791 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20071121/6f84c711/attachment.bin>


More information about the Gcc-patches mailing list