On Wed, May 17, 2023 at 12:32 PM Jonathan Wakely wrote: > -template > - _OutputIterator > -__brick_generate_n(_OutputIterator __first, _Size __count, _Generator > __g, /* is_vector = */ std::true_type) noexcept > +template > > Missing uglification on Size. > > +_RandomAccessIterator > +__brick_generate_n(_RandomAccessIterator __first, Size __count, > _Generator __g, > + /* is_vector = */ std::true_type) noexcept > { > return __unseq_backend::__simd_generate_n(__first, __count, __g); > } > > -template > - _OutputIterator > -__brick_generate_n(_OutputIterator __first, _Size __count, _Generator > __g, /* is_vector = */ std::false_type) noexcept > +template > > Missing uglification on OutputIterator and Size. > > +OutputIterator > +__brick_generate_n(OutputIterator __first, Size __count, _Generator __g, > /* is_vector = */ std::false_type) noexcept > > > -template _BinaryOperation> > -_ForwardIterator2 > -__brick_adjacent_difference(_ForwardIterator1 __first, _ForwardIterator1 > __last, _ForwardIterator2 __d_first, > - _BinaryOperation __op, /*is_vector=*/std::true_type) noexcept > +template class BinaryOperation> > > Missing uglification on BinaryOperation. > > +_RandomAccessIterator2 > +__brick_adjacent_difference(_RandomAccessIterator1 __first, > _RandomAccessIterator1 __last, > + _RandomAccessIterator2 __d_first, > BinaryOperation __op, > + /*is_vector=*/std::true_type) noexcept > > > The above problems exist on the declaration and the definitions. > > > --- a/libstdc++-v3/include/pstl/glue_execution_defs.h > +++ b/libstdc++-v3/include/pstl/glue_execution_defs.h > @@ -18,8 +18,8 @@ namespace std > { > // Type trait > using __pstl::execution::is_execution_policy; > -#if _PSTL_CPP14_VARIABLE_TEMPLATES_PRESENT > -# if __INTEL_COMPILER > +#if defined(_PSTL_CPP14_VARIABLE_TEMPLATES_PRESENT) > +# if defined(__INTEL_COMPILER) > template > constexpr bool is_execution_policy_v = is_execution_policy::value; > # else > > Pre-existing, but that T should be _Tp, but it only affects the Intel > compiler branch, so meh. > > Please fix these and report them upstream too. > Ack. > > All the actual code changes look good. > > I think I'd prefer if __pattern_partial_sort_copy used > std::uninitialized_copy instead of a loop and placement-new, but that > doesn't need to hold this up. We could optimize some uses of > std::conjunction and std::conditional to use our own __and_ and > __conditional, but I'm not sure it's worth diverging from upstream to do > that. > > Please fix the naming bugs noted above and push to trunk, thanks! > There were a handful of additional missed uglifications in - * libstdc++-v3/include/pstl/glue_algorithm_impl.h * libstdc++-v3/include/pstl/unseq_backend_simd.h That are in this commit, but not in the patch as reviewed. Tested x86_64-linux. Pushed to trunk. > > +Reviewed-by: Jonathan Wakely > > > > > >