Init
This commit is contained in:
53
cppdraft/algorithms/parallel/overloads.md
Normal file
53
cppdraft/algorithms/parallel/overloads.md
Normal file
@@ -0,0 +1,53 @@
|
||||
[algorithms.parallel.overloads]
|
||||
|
||||
# 26 Algorithms library [[algorithms]](./#algorithms)
|
||||
|
||||
## 26.3 Parallel algorithms [[algorithms.parallel]](algorithms.parallel#overloads)
|
||||
|
||||
### 26.3.5 Parallel algorithm overloads [algorithms.parallel.overloads]
|
||||
|
||||
[1](#1)
|
||||
|
||||
[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/algorithms.tex#L598)
|
||||
|
||||
Parallel algorithms are algorithm overloads[.](#1.sentence-1)
|
||||
|
||||
Each parallel algorithm overload
|
||||
has an additional function parameter P of type T&& as the first function parameter,
|
||||
where T is the execution policy template parameter[.](#1.sentence-2)
|
||||
|
||||
[*Note [1](#note-1)*:
|
||||
|
||||
Not all algorithms have parallel algorithm overloads[.](#1.sentence-3)
|
||||
|
||||
â *end note*]
|
||||
|
||||
[2](#2)
|
||||
|
||||
[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/algorithms.tex#L608)
|
||||
|
||||
Unless otherwise specified,
|
||||
the semantics of calling a parallel algorithm overload are identical to
|
||||
calling the corresponding algorithm overload without the parameter P,
|
||||
using all but the first argument[.](#2.sentence-1)
|
||||
|
||||
[3](#3)
|
||||
|
||||
[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/algorithms.tex#L614)
|
||||
|
||||
Unless otherwise specified,
|
||||
the complexity requirements of a parallel algorithm overload
|
||||
are relaxed from the complexity requirements of the corresponding overload
|
||||
without the parameter P as follows:
|
||||
when the guarantee says âat most *expr*â or
|
||||
âexactly *expr*â
|
||||
and does not specify the number of assignments or swaps, and*expr* is not already expressed with O() notation,
|
||||
the complexity of the algorithm shall be O(expr)[.](#3.sentence-1)
|
||||
|
||||
[4](#4)
|
||||
|
||||
[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/algorithms.tex#L626)
|
||||
|
||||
A parallel algorithm
|
||||
with a template parameter named ExecutionPolicy shall not participate in overload resolution unless
|
||||
that template parameter satisfies [*execution-policy*](algorithms.parallel.defns#concept:execution-policy "26.3.1 Preamble [algorithms.parallel.defns]")[.](#4.sentence-1)
|
||||
Reference in New Issue
Block a user