From Jason Turner

[algorithms.parallel.overloads]

Diff to HTML by rtfpessoa

Files changed (1) hide show
  1. tmp/tmp_wys68t9/{from.md → to.md} +16 -15
tmp/tmp_wys68t9/{from.md → to.md} RENAMED
@@ -1,25 +1,26 @@
1
- ### `ExecutionPolicy` algorithm overloads <a id="algorithms.parallel.overloads">[[algorithms.parallel.overloads]]</a>
2
 
3
  Parallel algorithms are algorithm overloads. Each parallel algorithm
4
- overload has an additional template type parameter named
5
- `ExecutionPolicy`, which is the first template parameter. Additionally,
6
- each parallel algorithm overload has an additional function parameter of
7
- type `ExecutionPolicy&&`, which is the first function parameter.
8
 
9
  [*Note 1*: Not all algorithms have parallel algorithm
10
  overloads. — *end note*]
11
 
12
- Unless otherwise specified, the semantics of `ExecutionPolicy` algorithm
13
- overloads are identical to their overloads without.
 
14
 
15
- Unless otherwise specified, the complexity requirements of
16
- `ExecutionPolicy` algorithm overloads are relaxed from the complexity
17
- requirements of the overloads without as follows: when the guarantee
18
- says “at most *expr*” or “exactly *expr*” and does not specify the
19
- number of assignments or swaps, and *expr* is not already expressed with
20
- 𝑂() notation, the complexity of the algorithm shall be
21
  𝑂(\placeholder{expr}).
22
 
23
- Parallel algorithms shall not participate in overload resolution unless
24
- `is_execution_policy_v<remove_cvref_t<ExecutionPolicy>>` is `true`.
 
25
 
 
1
+ ### Parallel algorithm overloads <a id="algorithms.parallel.overloads">[[algorithms.parallel.overloads]]</a>
2
 
3
  Parallel algorithms are algorithm overloads. Each parallel algorithm
4
+ overload has an additional function parameter P of type `T&&` as the
5
+ first function parameter, where `T` is the execution policy template
6
+ parameter.
 
7
 
8
  [*Note 1*: Not all algorithms have parallel algorithm
9
  overloads. — *end note*]
10
 
11
+ Unless otherwise specified, the semantics of calling a parallel
12
+ algorithm overload are identical to calling the corresponding algorithm
13
+ overload without the parameter P, using all but the first argument.
14
 
15
+ Unless otherwise specified, the complexity requirements of a parallel
16
+ algorithm overload are relaxed from the complexity requirements of the
17
+ corresponding overload without the parameter P as follows: when the
18
+ guarantee says “at most *expr*” or “exactly *expr*” and does not specify
19
+ the number of assignments or swaps, and *expr* is not already expressed
20
+ with 𝑂() notation, the complexity of the algorithm shall be
21
  𝑂(\placeholder{expr}).
22
 
23
+ A parallel algorithm with a template parameter named `ExecutionPolicy`
24
+ shall not participate in overload resolution unless that template
25
+ parameter satisfies `execution-policy`.
26