@@ -17,7 +17,7 @@ a set of non-standard parallel algorithms.
1717
1818 parallel_api/execution_policies.rst
1919
20- Buffer wrappers
20+ Buffer Wrappers
2121+++++++++++++++
2222
2323.. code :: cpp
@@ -89,8 +89,8 @@ for ``begin`` and ``end``. Otherwise, the behavior is undefined.
8989 Iterators
9090+++++++++
9191
92- The oneDPL iterators are defined in the :code: ` <oneapi/dpl/iterator> ` header,
93- in :code: ` namespace oneapi::dpl `.
92+ The oneDPL iterators are defined in the `` <oneapi/dpl/iterator> ` ` header,
93+ in `` namespace oneapi::dpl ` `.
9494
9595.. code :: cpp
9696
@@ -129,10 +129,10 @@ in :code:`namespace oneapi::dpl`.
129129 bool operator>=(const counting_iterator& it) const;
130130 };
131131
132- :code: ` counting_iterator ` is a random access iterator-like type that represents an integer counter.
133- When dereferenced, :code: ` counting_iterator ` provides an Integral rvalue equal to the value of the
132+ `` counting_iterator ` ` is a random access iterator-like type that represents an integer counter.
133+ When dereferenced, `` counting_iterator ` ` provides an Integral rvalue equal to the value of the
134134counter; dereference operations cannot be used to modify the counter. The arithmetic and comparison
135- operators of :code: ` counting_iterator ` behave as if applied to the values of Integral type
135+ operators of `` counting_iterator ` ` behave as if applied to the values of Integral type
136136representing the counters of the iterator instances passed to the operators.
137137
138138.. code :: cpp
@@ -169,10 +169,10 @@ representing the counters of the iterator instances passed to the operators.
169169 bool operator>(const discard_iterator& it) const;
170170 };
171171
172- :code: ` discard_iterator ` is a random access iterator-like type that, when dereferenced, provides an
172+ `` discard_iterator ` ` is a random access iterator-like type that, when dereferenced, provides an
173173lvalue that may be assigned an arbitrary value. The assignment has no effect on the
174- :code: ` discard_iterator ` instance; the write is discarded. The arithmetic and comparison operators
175- of :code: ` discard_iterator ` behave as if applied to integer counter values maintained by the
174+ `` discard_iterator ` ` instance; the write is discarded. The arithmetic and comparison operators
175+ of `` discard_iterator ` ` behave as if applied to integer counter values maintained by the
176176iterator instances to determine their position relative to each other.
177177
178178.. code :: cpp
@@ -216,19 +216,19 @@ iterator instances to determine their position relative to each other.
216216 bool operator>=(const permutation_iterator& it) const;
217217 };
218218
219- :code: ` permutation_iterator ` is a random access iterator-like type whose dereferenced value set is
219+ `` permutation_iterator ` ` is a random access iterator-like type whose dereferenced value set is
220220defined by the source iterator provided, and whose iteration order over the dereferenced value set
221- is defined by either another iterator or a functor that maps the :code: ` permutation_iterator ` index
221+ is defined by either another iterator or a functor that maps the `` permutation_iterator ` ` index
222222to the index of the source iterator. The arithmetic and comparison operators of
223- :code: ` permutation_iterator ` behave as if applied to integer counter values maintained by the
223+ `` permutation_iterator ` ` behave as if applied to integer counter values maintained by the
224224iterator instances to determine their position in the index map.
225225
226- :code: ` permutation_iterator::operator* ` uses the counter value of the instance on which
226+ `` permutation_iterator::operator* ` ` uses the counter value of the instance on which
227227it is invoked to index into the index map. The corresponding value in the map is then used
228228to index into the value set defined by the source iterator. The resulting lvalue is returned
229229as the result of the operator.
230230
231- :code: ` permutation_iterator::operator[] ` uses the parameter :code: ` i `
231+ `` permutation_iterator::operator[] `` uses the parameter `` i ``
232232to index into the index map. The corresponding value in the map is then used
233233to index into the value set defined by the source iterator. The resulting lvalue is returned
234234as the result of the operator.
@@ -239,7 +239,7 @@ as the result of the operator.
239239 permutation_iterator<SourceIterator, IndexMap>
240240 make_permutation_iterator(SourceIterator source, IndexMap map);
241241
242- :code: ` make_permutation_iterator ` constructs and returns an instance of :code: ` permutation_iterator `
242+ `` make_permutation_iterator `` constructs and returns an instance of `` permutation_iterator ` `
243243using the source iterator and index map provided.
244244
245245.. code :: cpp
@@ -284,12 +284,12 @@ using the source iterator and index map provided.
284284 bool operator>=(const transform_iterator& it) const;
285285 };
286286
287- :code: ` transform_iterator ` is a random access iterator-like type whose dereferenced value set is
287+ `` transform_iterator ` ` is a random access iterator-like type whose dereferenced value set is
288288defined by the unary function and source iterator provided. When dereferenced,
289- :code: ` transform_iterator ` provides the result of the unary function applied to the corresponding
289+ `` transform_iterator ` ` provides the result of the unary function applied to the corresponding
290290element of the source iterator; dereference operations cannot be used to modify the elements of
291291the source iterator unless the unary function result includes a reference to the element. The
292- arithmetic and comparison operators of :code: ` transform_iterator ` behave as if applied to the
292+ arithmetic and comparison operators of `` transform_iterator ` ` behave as if applied to the
293293source iterator itself.
294294
295295.. code :: cpp
@@ -298,7 +298,7 @@ source iterator itself.
298298 transform_iterator<UnaryFunc, Iterator>
299299 make_transform_iterator(Iterator, UnaryFunc);
300300
301- :code: ` make_transform_iterator ` constructs and returns an instance of :code: ` transform_iterator `
301+ `` make_transform_iterator `` constructs and returns an instance of `` transform_iterator ` `
302302using the source iterator and unary function object provided.
303303
304304.. code :: cpp
@@ -344,10 +344,10 @@ using the source iterator and unary function object provided.
344344 bool operator>=(const zip_iterator& it) const;
345345 };
346346
347- :code: ` zip_iterator ` is an iterator-like type defined over one or more iterators. When dereferenced,
348- the value returned from :code: ` zip_iterator ` is a tuple of the values returned by dereferencing the
349- source iterators over which the :code: ` zip_iterator ` is defined. The arithmetic operators of
350- :code: ` zip_iterator ` update the source iterators of a :code: ` zip_iterator ` instance as though the
347+ `` zip_iterator ` ` is an iterator-like type defined over one or more iterators. When dereferenced,
348+ the value returned from `` zip_iterator ` ` is a tuple of the values returned by dereferencing the
349+ source iterators over which the `` zip_iterator `` is defined. The arithmetic operators of
350+ `` zip_iterator `` update the source iterators of a `` zip_iterator ` ` instance as though the
351351operation were applied to each of these iterators.
352352
353353.. code :: cpp
@@ -356,14 +356,14 @@ operation were applied to each of these iterators.
356356 zip_iterator<Iterators...>
357357 make_zip_iterator(Iterators...);
358358
359- :code: ` make_zip_iterator ` constructs and returns an instance of :code: ` zip_iterator `
359+ `` make_zip_iterator `` constructs and returns an instance of `` zip_iterator ` `
360360using the set of source iterators provided.
361361
362362Parallel Algorithms
363363+++++++++++++++++++
364364
365- The parallel algorithms are defined in the :code: ` <oneapi/dpl/algorithm> ` header,
366- in :code: ` namespace oneapi::dpl `.
365+ The parallel algorithms are defined in the `` <oneapi/dpl/algorithm> ` ` header,
366+ in `` namespace oneapi::dpl ` `.
367367
368368.. code :: cpp
369369
@@ -383,17 +383,17 @@ in :code:`namespace oneapi::dpl`.
383383 BinaryOp binary_op =
384384 std::plus<typename std::iterator_traits<InputValueIt>::value_type>());
385385
386- :code: ` oneapi::dpl::exclusive_scan_by_segment ` performs partial prefix scans by applying the
387- :code: ` binary_op ` operation to a sequence of values. Each partial scan applies to a contiguous
386+ `` oneapi::dpl::exclusive_scan_by_segment ` ` performs partial prefix scans by applying the
387+ `` binary_op ` ` operation to a sequence of values. Each partial scan applies to a contiguous
388388subsequence determined by the keys associated with the values being equal according to the
389- :code: ` binary_pred ` predicate, and the first element of each scan is the initial value provided.
389+ `` binary_pred ` ` predicate, and the first element of each scan is the initial value provided.
390390The return value is an iterator targeting the end of the result sequence.
391391
392- The initial value used if one is not provided is an instance of the :code: ` value_type ` of the
393- :code: ` InputValueIt ` iterator type initialized to 0. If no binary predicate is provided for the
394- comparison of keys an instance of :code: ` std::equal_to ` with the :code: ` value_type ` of the
395- :code: ` InputKeyIt ` iterator type is used. Finally, an instance of :code: ` std::plus ` with the
396- :code: ` value_type ` of the :code: ` InputValueIt ` iterator type is used if no binary operator is
392+ The initial value used if one is not provided is an instance of the `` value_type ` ` of the
393+ `` InputValueIt ` ` iterator type initialized to 0. If no binary predicate is provided for the
394+ comparison of keys an instance of `` std::equal_to `` with the `` value_type ` ` of the
395+ `` InputKeyIt `` iterator type is used. Finally, an instance of `` std::plus ` ` with the
396+ `` value_type `` of the `` InputValueIt ` ` iterator type is used if no binary operator is
397397provided to combine the elements of the value subsequences.
398398
399399.. code :: cpp
@@ -412,15 +412,15 @@ provided to combine the elements of the value subsequences.
412412 BinaryOp binary_op =
413413 std::plus<typename std::iterator_traits<InputValueIt>::value_type>());
414414
415- :code: ` oneapi::dpl::inclusive_scan_by_segment ` performs partial prefix scans by applying the
416- :code: ` binary_op ` operation to a sequence of values. Each partial scan applies to a contiguous
415+ `` oneapi::dpl::inclusive_scan_by_segment ` ` performs partial prefix scans by applying the
416+ `` binary_op ` ` operation to a sequence of values. Each partial scan applies to a contiguous
417417subsequence determined by the keys associated with the values being equal according to the
418- :code: ` binary_pred ` predicate. The return value is an iterator targeting the end of the result
418+ `` binary_pred ` ` predicate. The return value is an iterator targeting the end of the result
419419sequence.
420420
421- If no binary predicate is provided for the comparison of keys an instance of :code: ` std::equal_to `
422- with the :code: ` value_type ` of the :code: ` InputKeyIt ` iterator type is used. An instance of
423- :code: ` std::plus ` with the :code: ` value_type ` of the :code: ` InputValueIt ` iterator type is used if
421+ If no binary predicate is provided for the comparison of keys an instance of `` std::equal_to ` `
422+ with the `` value_type `` of the `` InputKeyIt `` iterator type is used. An instance of
423+ `` std::plus `` with the `` value_type `` of the `` InputValueIt ` ` iterator type is used if
424424no binary operator is provided to combine the elements of the value subsequences.
425425
426426.. code :: cpp
@@ -440,16 +440,16 @@ no binary operator is provided to combine the elements of the value subsequences
440440 BinaryOp binary_op =
441441 std::plus<typename std::iterator_traits<InputValueIt>::value_type>());
442442
443- :code: ` oneapi::dpl::reduce_by_segment ` performs partial reductions on a sequence of values. Each
444- reduction is computed with the :code: ` binary_op ` operation for a contiguous subsequence of values
445- determined by the associated keys being equal according to the :code: ` binary_pred ` predicate.
446- For each subsequence the first of the equal keys is stored into :code: ` keys_result ` and the computed
447- reduction is stored into :code: ` values_result `. The return value is a pair of
443+ `` oneapi::dpl::reduce_by_segment ` ` performs partial reductions on a sequence of values. Each
444+ reduction is computed with the `` binary_op ` ` operation for a contiguous subsequence of values
445+ determined by the associated keys being equal according to the `` binary_pred ` ` predicate.
446+ For each subsequence the first of the equal keys is stored into `` keys_result ` ` and the computed
447+ reduction is stored into `` values_result ` `. The return value is a pair of
448448iterators holding the end of the resulting sequences.
449449
450- If no binary predicate is provided for the comparison of keys an instance of :code: ` std::equal_to `
451- with the :code: ` value_type ` of the :code: ` InputKeyIt ` iterator type is used. An instance of
452- :code: ` std::plus ` with the :code: ` value_type ` of the :code: ` InputValueIt ` iterator type is used to
450+ If no binary predicate is provided for the comparison of keys an instance of `` std::equal_to ` `
451+ with the `` value_type `` of the `` InputKeyIt ` ` iterator type is used. An instance of
452+ `` std::plus `` with the `` value_type `` of the `` InputValueIt ` ` iterator type is used to
453453combine the values in each subsequence identified if a binary operator is not provided.
454454
455455.. code :: cpp
@@ -463,16 +463,17 @@ combine the values in each subsequence identified if a binary operator is not pr
463463 Comparator comp =
464464 std::less<typename std::iterator_traits<InputIt1>::value_type>());
465465
466- :code: ` oneapi::dpl::binary_search ` performs a binary search over the data in :code: ` [start, end) `
467- for each value in :code: ` [value_first, value_last) `. If the value exists in the data searched then
468- the corresponding element in :code: ` [result, result + distance(value_first, value_last)) ` is set to
466+ `` oneapi::dpl::binary_search `` performs a binary search over the data in `` [start, end) ` `
467+ for each value in `` [value_first, value_last) ``. If the value exists in the data searched then
468+ the corresponding element in `` [result, result + distance(value_first, value_last)) ` ` is set to
469469true, otherwise it is set to false.
470470
471- If no comparator is provided, :code: ` operator< ` is used to determine when the search value is less
471+ If no comparator is provided, `` operator< ` ` is used to determine when the search value is less
472472than an element in the range being searched.
473473
474- The elements e of [start, end) must be partitioned with respect to the comparator used. For all
475- elements e in [start, end) and a given search value v in [value_first, value_last) comp(e, v) implies !comp(v, e).
474+ The elements of ``[start, end) `` must be partitioned with respect to the comparator used. For all
475+ elements ``e `` in ``[start, end) `` and a given search value ``v `` in ``[value_first, value_last) ``,
476+ ``comp(e, v) `` implies ``!comp(v, e) ``.
476477
477478.. code :: cpp
478479
@@ -485,16 +486,16 @@ elements e in [start, end) and a given search value v in [value_first, value_las
485486 Comparator comp =
486487 std::less<typename std::iterator_traits<InputIt1>::value_type>());
487488
488- :code: ` oneapi::dpl::lower_bound ` performs a binary search over the data in :code: ` [start, end) ` for
489- each value in :code: ` [value_first, value_last) ` to find the lowest index at which the search value
490- could be inserted in :code: ` [start, end) ` without violating the ordering defined by the comparator
489+ `` oneapi::dpl::lower_bound `` performs a binary search over the data in `` [start, end) ` ` for
490+ each value in `` [value_first, value_last) ` ` to find the lowest index at which the search value
491+ could be inserted in `` [start, end) ` ` without violating the ordering defined by the comparator
491492provided. That lowest index is then assigned to the corresponding element in
492- :code: ` [result, result + distance(value_first, value_last)) `.
493+ `` [result, result + distance(value_first, value_last)) ` `.
493494
494- If no comparator is provided, :code: ` operator< ` is used to determine when the search value is less
495+ If no comparator is provided, `` operator< ` ` is used to determine when the search value is less
495496than an element in the range being searched.
496497
497- The elements e of [start, end) must be partitioned with respect to the comparator used.
498+ The elements of `` [start, end) `` must be partitioned with respect to the comparator used.
498499
499500.. code :: cpp
500501
@@ -507,16 +508,16 @@ The elements e of [start, end) must be partitioned with respect to the comparato
507508 Comparator comp =
508509 std::less<typename std::iterator_traits<InputIt1>::value_type>());
509510
510- :code: ` oneapi::dpl::upper_bound ` performs a binary search over the data in :code: ` [start, end) `
511- for each value in :code: ` [value_first, value_last) ` to find the highest index at which the search
512- value could be inserted in :code: ` [start, end) ` without violating the ordering defined by the
511+ `` oneapi::dpl::upper_bound `` performs a binary search over the data in `` [start, end) ` `
512+ for each value in `` [value_first, value_last) ` ` to find the highest index at which the search
513+ value could be inserted in `` [start, end) ` ` without violating the ordering defined by the
513514comparator provided. That highest index is then assigned to the corresponding element in
514- :code: ` [result, result + distance(value_first, value_last)) `.
515+ `` [result, result + distance(value_first, value_last)) ` `.
515516
516- If no comparator is provided, :code: ` operator< ` is used to determine when the search value is less
517+ If no comparator is provided, `` operator< ` ` is used to determine when the search value is less
517518than an element in the range being searched.
518519
519- The elements e of [start, end) must be partitioned with respect to the comparator used.
520+ The elements of `` [start, end) `` must be partitioned with respect to the comparator used.
520521
521522.. _`C++ Standard` : https://isocpp.org/std/the-standard
522523.. _`SYCL` : https://registry.khronos.org/SYCL/specs/sycl-2020/html/sycl-2020.html
0 commit comments