[PATCH][libstdc++-v3 parallel mode] Ambiguities (incl. std::mismatch)
Johannes Singler
singler@kit.edu
Tue Jan 25 18:28:00 GMT 2011
On 01/24/2011 08:05 PM, Paolo Carlini wrote:
> On 01/24/2011 07:45 PM, Johannes Singler wrote:
>> Well, I have an test case that fails to compile with this version
>> (ambiguity), when calling __gnu_parallel::equal (explicitly
>> qualified). Thus, I propose the attached patch. Does it still work
>> for you then, François?
> Not a requirement for applying the patch, which is Ok with me if
> Francois doesn't have other comments, but if you could also add that
> testcase it would be great.
I have come to the conclusion that my patch from 2010-03-22 was mostly
bogus (r157643), and deactivated parallel execution for the affected
routines in certain cases. The namespace _GLIBCXX_STD_P always suggests
"parallel", but it is the very opposite :-(
I have added test cases (for conformance) to existing files since this
is the problem of mixing implicit and explicit calls to the parallel
mode again.
Tested x86_64-unknown-linux-gnu: No regressions
Please approve for mainline and gcc-4_5-branch, also waiting for the
feedback of François.
2011-01-25 Johannes Singler <singler@kit.edu>
* include/parallel/numeric (inner_product, partial_sum):
Qualify subsequent call with __gnu_parallel instead of
_GLIBCXX_STD_P to reenable parallel execution without ambiguity.
* include/parallel/algobase.h (equal): Likewise.
* include/parallel/algo.h (find_first_of, search_n, merge,
nth_element, partial_sort, max_element, min_element): Likewise.
* testsuite/25_algorithms/headers/algorithm/
parallel_algorithm_mixed1.cc (main): Add respective test cases.
* testsuite/25_algorithms/headers/algorithm/
parallel_algorithm_mixed2.cc (main): Likewise.
* testsuite/26_numerics/headers/numeric/
parallel_numeric_mixed1.cc (main): Likewise.
* testsuite/26_numerics/headers/numeric/
parallel_numeric_mixed2.cc (main): Likewise.
Johannes
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ambiguities_corrected.patch
Type: text/x-patch
Size: 13924 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/libstdc++/attachments/20110125/f89bc539/attachment.bin>
More information about the Libstdc++
mailing list