Algorithms

## Classes

class | tbb::blocked_range< Value >
| A range over which to iterate. More...
class | tbb::blocked_range2d< RowValue, ColValue >
| A 2-dimensional range that models the Range concept. More...
class | tbb::blocked_range3d< PageValue, RowValue, ColValue >
| A 3-dimensional range that models the Range concept. More...
struct | tbb::pre_scan_tag
| Used to indicate that the initial scan is being performed. More...
struct | tbb::final_scan_tag
| Used to indicate that the final scan is being performed. More...
class | tbb::parallel_while< Body >
| Parallel iteration over a stream, with optional addition of more work. More...
class | tbb::filter
| A stage in a pipeline. More...
class | tbb::thread_bound_filter
| A stage in a pipeline served by a user thread. More...
class | tbb::pipeline
| A processing pipeline that applies filters to items. More...

## parallel_do

See also requirements on parallel_do Body.
template<typename Iterator , typename Body >
void | tbb::parallel_do (Iterator first, Iterator last, const Body &body)
| Parallel iteration over a range, with optional addition of more work. More...
template<typename Iterator , typename Body >
void | tbb::parallel_do (Iterator first, Iterator last, const Body &body, task_group_context &context)
| Parallel iteration over a range, with optional addition of more work and user-supplied context. More...
template<typename Range , typename Body >
void | tbb::parallel_do (Range &rng, const Body &body)
template<typename Range , typename Body >
void | tbb::parallel_do (const Range &rng, const Body &body)
template<typename Range , typename Body >
void | tbb::parallel_do (Range &rng, const Body &body, task_group_context &context)
template<typename Range , typename Body >
void | tbb::parallel_do (const Range &rng, const Body &body, task_group_context &context)

## parallel_for

See also requirements on Range and parallel_for Body.
template<typename Range , typename Body >
void | tbb::parallel_for (const Range &range, const Body &body)
| Parallel iteration over range with default partitioner. More...
template<typename Range , typename Body >
void | tbb::parallel_for (const Range &range, const Body &body, const simple_partitioner &partitioner)
| Parallel iteration over range with simple partitioner. More...
template<typename Range , typename Body >
void | tbb::parallel_for (const Range &range, const Body &body, const auto_partitioner &partitioner)
| Parallel iteration over range with auto_partitioner. More...
template<typename Range , typename Body >
void | tbb::parallel_for (const Range &range, const Body &body, const static_partitioner &partitioner)
| Parallel iteration over range with static_partitioner. More...
template<typename Range , typename Body >
void | tbb::parallel_for (const Range &range, const Body &body, affinity_partitioner &partitioner)
| Parallel iteration over range with affinity_partitioner. More...
template<typename Range , typename Body >
void | tbb::parallel_for (const Range &range, const Body &body, task_group_context &context)
| Parallel iteration over range with default partitioner and user-supplied context. More...
template<typename Range , typename Body >
void | tbb::parallel_for (const Range &range, const Body &body, const simple_partitioner &partitioner, task_group_context &context)
| Parallel iteration over range with simple partitioner and user-supplied context. More...
template<typename Range , typename Body >
void | tbb::parallel_for (const Range &range, const Body &body, const auto_partitioner &partitioner, task_group_context &context)
| Parallel iteration over range with auto_partitioner and user-supplied context. More...
template<typename Range , typename Body >
void | tbb::parallel_for (const Range &range, const Body &body, const static_partitioner &partitioner, task_group_context &context)
| Parallel iteration over range with static_partitioner and user-supplied context. More...
template<typename Range , typename Body >
void | tbb::parallel_for (const Range &range, const Body &body, affinity_partitioner &partitioner, task_group_context &context)
| Parallel iteration over range with affinity_partitioner and user-supplied context. More...

## parallel_for_each

template<typename Iterator , typename Function >
void | tbb::parallel_for_each (Iterator first, Iterator last, const Function &f, task_group_context &context)
| Calls function f for all items from [first, last) interval using user-supplied context. More...
template<typename Range , typename Function >
void | tbb::parallel_for_each (Range &rng, const Function &f, task_group_context &context)
| Calls function f for all items from rng using user-supplied context. More...
template<typename Range , typename Function >
void | tbb::parallel_for_each (const Range &rng, const Function &f, task_group_context &context)
| Calls function f for all items from const rng user-supplied context. More...
template<typename Iterator , typename Function >
void | tbb::parallel_for_each (Iterator first, Iterator last, const Function &f)
| Uses default context.
template<typename Range , typename Function >
void | tbb::parallel_for_each (Range &rng, const Function &f)
| Uses default context.
template<typename Range , typename Function >
void | tbb::parallel_for_each (const Range &rng, const Function &f)
| Uses default context.

## parallel_invoke

template<typename F0 , typename F1 , typename... F>
void | tbb::parallel_invoke (F0 &&f0, F1 &&f1, F &&...f)
| Executes a list of tasks in parallel and waits for all tasks to complete. More...
template<typename F0 , typename F1 >
void | tbb::parallel_invoke (const F0 &f0, const F1 &f1, tbb::task_group_context &context)
template<typename F0 , typename F1 , typename F2 >
void | tbb::parallel_invoke (const F0 &f0, const F1 &f1, const F2 &f2, tbb::task_group_context &context)
template<typename F0 , typename F1 , typename F2 , typename F3 >
void | tbb::parallel_invoke (const F0 &f0, const F1 &f1, const F2 &f2, const F3 &f3, tbb::task_group_context &context)
template<typename F0 , typename F1 , typename F2 , typename F3 , typename F4 >
void | tbb::parallel_invoke (const F0 &f0, const F1 &f1, const F2 &f2, const F3 &f3, const F4 &f4, tbb::task_group_context &context)
template<typename F0 , typename F1 , typename F2 , typename F3 , typename F4 , typename F5 >
void | tbb::parallel_invoke (const F0 &f0, const F1 &f1, const F2 &f2, const F3 &f3, const F4 &f4, const F5 &f5, tbb::task_group_context &context)
template<typename F0 , typename F1 , typename F2 , typename F3 , typename F4 , typename F5 , typename F6 >
void | tbb::parallel_invoke (const F0 &f0, const F1 &f1, const F2 &f2, const F3 &f3, const F4 &f4, const F5 &f5, const F6 &f6, tbb::task_group_context &context)
template<typename F0 , typename F1 , typename F2 , typename F3 , typename F4 , typename F5 , typename F6 , typename F7 >
void | tbb::parallel_invoke (const F0 &f0, const F1 &f1, const F2 &f2, const F3 &f3, const F4 &f4, const F5 &f5, const F6 &f6, const F7 &f7, tbb::task_group_context &context)
template<typename F0 , typename F1 , typename F2 , typename F3 , typename F4 , typename F5 , typename F6 , typename F7 , typename F8 >
void | tbb::parallel_invoke (const F0 &f0, const F1 &f1, const F2 &f2, const F3 &f3, const F4 &f4, const F5 &f5, const F6 &f6, const F7 &f7, const F8 &f8, tbb::task_group_context &context)
template<typename F0 , typename F1 , typename F2 , typename F3 , typename F4 , typename F5 , typename F6 , typename F7 , typename F8 , typename F9 >
void | tbb::parallel_invoke (const F0 &f0, const F1 &f1, const F2 &f2, const F3 &f3, const F4 &f4, const F5 &f5, const F6 &f6, const F7 &f7, const F8 &f8, const F9 &f9, tbb::task_group_context &context)
template<typename F0 , typename F1 >
void | tbb::parallel_invoke (const F0 &f0, const F1 &f1)
template<typename F0 , typename F1 , typename F2 >
void | tbb::parallel_invoke (const F0 &f0, const F1 &f1, const F2 &f2)
template<typename F0 , typename F1 , typename F2 , typename F3 >
void | tbb::parallel_invoke (const F0 &f0, const F1 &f1, const F2 &f2, const F3 &f3)
template<typename F0 , typename F1 , typename F2 , typename F3 , typename F4 >
void | tbb::parallel_invoke (const F0 &f0, const F1 &f1, const F2 &f2, const F3 &f3, const F4 &f4)
template<typename F0 , typename F1 , typename F2 , typename F3 , typename F4 , typename F5 >
void | tbb::parallel_invoke (const F0 &f0, const F1 &f1, const F2 &f2, const F3 &f3, const F4 &f4, const F5 &f5)
template<typename F0 , typename F1 , typename F2 , typename F3 , typename F4 , typename F5 , typename F6 >
void | tbb::parallel_invoke (const F0 &f0, const F1 &f1, const F2 &f2, const F3 &f3, const F4 &f4, const F5 &f5, const F6 &f6)
template<typename F0 , typename F1 , typename F2 , typename F3 , typename F4 , typename F5 , typename F6 , typename F7 >
void | tbb::parallel_invoke (const F0 &f0, const F1 &f1, const F2 &f2, const F3 &f3, const F4 &f4, const F5 &f5, const F6 &f6, const F7 &f7)
template<typename F0 , typename F1 , typename F2 , typename F3 , typename F4 , typename F5 , typename F6 , typename F7 , typename F8 >
void | tbb::parallel_invoke (const F0 &f0, const F1 &f1, const F2 &f2, const F3 &f3, const F4 &f4, const F5 &f5, const F6 &f6, const F7 &f7, const F8 &f8)
template<typename F0 , typename F1 , typename F2 , typename F3 , typename F4 , typename F5 , typename F6 , typename F7 , typename F8 , typename F9 >
void | tbb::parallel_invoke (const F0 &f0, const F1 &f1, const F2 &f2, const F3 &f3, const F4 &f4, const F5 &f5, const F6 &f6, const F7 &f7, const F8 &f8, const F9 &f9)

## parallel_reduce

See also requirements on Range and parallel_reduce Body.
template<typename Range , typename Body >
void | tbb::parallel_reduce (const Range &range, Body &body)
| Parallel iteration with reduction and default partitioner. More...
template<typename Range , typename Body >
void | tbb::parallel_reduce (const Range &range, Body &body, const simple_partitioner &partitioner)
| Parallel iteration with reduction and simple_partitioner. More...
template<typename Range , typename Body >
void | tbb::parallel_reduce (const Range &range, Body &body, const auto_partitioner &partitioner)
| Parallel iteration with reduction and auto_partitioner. More...
template<typename Range , typename Body >
void | tbb::parallel_reduce (const Range &range, Body &body, const static_partitioner &partitioner)
| Parallel iteration with reduction and static_partitioner. More...
template<typename Range , typename Body >
void | tbb::parallel_reduce (const Range &range, Body &body, affinity_partitioner &partitioner)
| Parallel iteration with reduction and affinity_partitioner. More...
template<typename Range , typename Body >
void | tbb::parallel_reduce (const Range &range, Body &body, const simple_partitioner &partitioner, task_group_context &context)
| Parallel iteration with reduction, simple partitioner and user-supplied context. More...
template<typename Range , typename Body >
void | tbb::parallel_reduce (const Range &range, Body &body, const auto_partitioner &partitioner, task_group_context &context)
| Parallel iteration with reduction, auto_partitioner and user-supplied context. More...
template<typename Range , typename Body >
void | tbb::parallel_reduce (const Range &range, Body &body, const static_partitioner &partitioner, task_group_context &context)
| Parallel iteration with reduction, static_partitioner and user-supplied context. More...
template<typename Range , typename Body >
void | tbb::parallel_reduce (const Range &range, Body &body, affinity_partitioner &partitioner, task_group_context &context)
| Parallel iteration with reduction, affinity_partitioner and user-supplied context. More...
template<typename Range , typename Value , typename RealBody , typename Reduction >
Value | tbb::parallel_reduce (const Range &range, const Value &identity, const RealBody &real_body, const Reduction &reduction)
| Parallel iteration with reduction and default partitioner. More...
template<typename Range , typename Value , typename RealBody , typename Reduction >
Value | tbb::parallel_reduce (const Range &range, const Value &identity, const RealBody &real_body, const Reduction &reduction, const simple_partitioner &partitioner)
| Parallel iteration with reduction and simple_partitioner. More...
template<typename Range , typename Value , typename RealBody , typename Reduction >
Value | tbb::parallel_reduce (const Range &range, const Value &identity, const RealBody &real_body, const Reduction &reduction, const auto_partitioner &partitioner)
| Parallel iteration with reduction and auto_partitioner. More...
template<typename Range , typename Value , typename RealBody , typename Reduction >
Value | tbb::parallel_reduce (const Range &range, const Value &identity, const RealBody &real_body, const Reduction &reduction, const static_partitioner &partitioner)
| Parallel iteration with reduction and static_partitioner. More...
template<typename Range , typename Value , typename RealBody , typename Reduction >
Value | tbb::parallel_reduce (const Range &range, const Value &identity, const RealBody &real_body, const Reduction &reduction, affinity_partitioner &partitioner)
| Parallel iteration with reduction and affinity_partitioner. More...
template<typename Range , typename Value , typename RealBody , typename Reduction >
Value | tbb::parallel_reduce (const Range &range, const Value &identity, const RealBody &real_body, const Reduction &reduction, const simple_partitioner &partitioner, task_group_context &context)
| Parallel iteration with reduction, simple partitioner and user-supplied context. More...
template<typename Range , typename Value , typename RealBody , typename Reduction >
Value | tbb::parallel_reduce (const Range &range, const Value &identity, const RealBody &real_body, const Reduction &reduction, const auto_partitioner &partitioner, task_group_context &context)
| Parallel iteration with reduction, auto_partitioner and user-supplied context. More...
template<typename Range , typename Value , typename RealBody , typename Reduction >
Value | tbb::parallel_reduce (const Range &range, const Value &identity, const RealBody &real_body, const Reduction &reduction, const static_partitioner &partitioner, task_group_context &context)
| Parallel iteration with reduction, static_partitioner and user-supplied context. More...
template<typename Range , typename Value , typename RealBody , typename Reduction >
Value | tbb::parallel_reduce (const Range &range, const Value &identity, const RealBody &real_body, const Reduction &reduction, affinity_partitioner &partitioner, task_group_context &context)
| Parallel iteration with reduction, affinity_partitioner and user-supplied context. More...
template<typename Range , typename Body >
void | tbb::parallel_deterministic_reduce (const Range &range, Body &body)
| Parallel iteration with deterministic reduction and default partitioner. More...
template<typename Range , typename Body >
void | tbb::parallel_deterministic_reduce (const Range &range, Body &body, task_group_context &context)
| Parallel iteration with deterministic reduction, simple partitioner and user-supplied context. More...
template<typename Range , typename Value , typename RealBody , typename Reduction >
Value | tbb::parallel_deterministic_reduce (const Range &range, const Value &identity, const RealBody &real_body, const Reduction &reduction)
| Parallel iteration with deterministic reduction and default partitioner. More...
template<typename Range , typename Value , typename RealBody , typename Reduction >
Value | tbb::parallel_deterministic_reduce (const Range &range, const Value &identity, const RealBody &real_body, const Reduction &reduction, task_group_context &context)
| Parallel iteration with deterministic reduction, simple partitioner and user-supplied context. More...

## parallel_scan

See also requirements on Range and parallel_scan Body.
template<typename Range , typename Body >
void | tbb::parallel_scan (const Range &range, Body &body)
| Parallel prefix with default partitioner. More...
template<typename Range , typename Body >
void | tbb::parallel_scan (const Range &range, Body &body, const simple_partitioner &partitioner)
| Parallel prefix with simple_partitioner. More...
template<typename Range , typename Body >
void | tbb::parallel_scan (const Range &range, Body &body, const auto_partitioner &partitioner)
| Parallel prefix with auto_partitioner. More...

## parallel_sort

See also requirements on iterators for parallel_sort.
template<typename RandomAccessIterator , typename Compare >
void | tbb::parallel_sort (RandomAccessIterator begin, RandomAccessIterator end, const Compare &comp)
| Sorts the data in [begin,end) using the given comparator. More...
template<typename RandomAccessIterator >
void | tbb::parallel_sort (RandomAccessIterator begin, RandomAccessIterator end)
| Sorts the data in [begin,end) with a default comparator `std::less<RandomAccessIterator>` More...
template<typename Range , typename Compare >
void | tbb::parallel_sort (Range &rng, const Compare &comp)
| Sorts the data in rng using the given comparator. More...
template<typename Range , typename Compare >
void | tbb::parallel_sort (const Range &rng, const Compare &comp)
| Sorts the data in const rng using the given comparator. More...
template<typename Range >
void | tbb::parallel_sort (Range &rng)
| Sorts the data in rng with a default comparator `std::less<RandomAccessIterator>` More...
template<typename Range >
void | tbb::parallel_sort (const Range &rng)
| Sorts the data in const rng with a default comparator `std::less<RandomAccessIterator>` More...
template<typename T >
void | tbb::parallel_sort (T *begin, T *end)
| Sorts the data in the range ``[begin,end) with a default comparator `std::less<T>` More...

## Detailed Description

## Function Documentation

template<typename Range , typename Body >

void tbb::parallel_deterministic_reduce | ( | const Range & | range,
|  | Body & | body
| ) |  |

Parallel iteration with deterministic reduction and default partitioner.

template<typename Range , typename Body >

void tbb::parallel_deterministic_reduce | ( | const Range & | range,
|  | Body & | body,
|  | task_group_context & | context
| ) |  |

Parallel iteration with deterministic reduction, simple partitioner and user-supplied context.

template<typename Range , typename Value , typename RealBody , typename Reduction >

Value tbb::parallel_deterministic_reduce | ( | const Range & | range,
|  | const Value & | identity,
|  | const RealBody & | real_body,
|  | const Reduction & | reduction
| ) |  |

Parallel iteration with deterministic reduction and default partitioner.

parallel_reduce overloads that work with anonymous function objects (see also requirements on parallel_reduce anonymous function objects).

template<typename Range , typename Value , typename RealBody , typename Reduction >

Value tbb::parallel_deterministic_reduce | ( | const Range & | range,
|  | const Value & | identity,
|  | const RealBody & | real_body,
|  | const Reduction & | reduction,
|  | task_group_context & | context
| ) |  |

Parallel iteration with deterministic reduction, simple partitioner and user-supplied context.

template<typename Iterator , typename Body >

void tbb::parallel_do | ( | Iterator | first,
|  | Iterator | last,
|  | const Body & | body
| ) |  |

Parallel iteration over a range, with optional addition of more work.

template<typename Iterator , typename Body >

void tbb::parallel_do | ( | Iterator | first,
|  | Iterator | last,
|  | const Body & | body,
|  | task_group_context & | context
| ) |  |

Parallel iteration over a range, with optional addition of more work and user-supplied context.

template<typename Range , typename Body >

void tbb::parallel_for | ( | const Range & | range,
|  | const Body & | body
| ) |  |

Parallel iteration over range with default partitioner.

template<typename Range , typename Body >

void tbb::parallel_for | ( | const Range & | range,
|  | const Body & | body,
|  | const simple_partitioner & | partitioner
| ) |  |

Parallel iteration over range with simple partitioner.

template<typename Range , typename Body >

void tbb::parallel_for | ( | const Range & | range,
|  | const Body & | body,
|  | const auto_partitioner & | partitioner
| ) |  |

Parallel iteration over range with auto_partitioner.

template<typename Range , typename Body >

void tbb::parallel_for | ( | const Range & | range,
|  | const Body & | body,
|  | const static_partitioner & | partitioner
| ) |  |

Parallel iteration over range with static_partitioner.

template<typename Range , typename Body >

void tbb::parallel_for | ( | const Range & | range,
|  | const Body & | body,
|  | affinity_partitioner & | partitioner
| ) |  |

Parallel iteration over range with affinity_partitioner.

template<typename Range , typename Body >

void tbb::parallel_for | ( | const Range & | range,
|  | const Body & | body,
|  | task_group_context & | context
| ) |  |

Parallel iteration over range with default partitioner and user-supplied context.

template<typename Range , typename Body >

void tbb::parallel_for | ( | const Range & | range,
|  | const Body & | body,
|  | const simple_partitioner & | partitioner,
|  | task_group_context & | context
| ) |  |

Parallel iteration over range with simple partitioner and user-supplied context.

template<typename Range , typename Body >

void tbb::parallel_for | ( | const Range & | range,
|  | const Body & | body,
|  | const auto_partitioner & | partitioner,
|  | task_group_context & | context
| ) |  |

Parallel iteration over range with auto_partitioner and user-supplied context.

template<typename Range , typename Body >

void tbb::parallel_for | ( | const Range & | range,
|  | const Body & | body,
|  | const static_partitioner & | partitioner,
|  | task_group_context & | context
| ) |  |

Parallel iteration over range with static_partitioner and user-supplied context.

template<typename Range , typename Body >

void tbb::parallel_for | ( | const Range & | range,
|  | const Body & | body,
|  | affinity_partitioner & | partitioner,
|  | task_group_context & | context
| ) |  |

Parallel iteration over range with affinity_partitioner and user-supplied context.

template<typename Iterator , typename Function >

void tbb::parallel_for_each | ( | Iterator | first,
|  | Iterator | last,
|  | const Function & | f,
|  | task_group_context & | context
| ) |  |

Calls function f for all items from [first, last) interval using user-supplied context.

Referenced by tbb::parallel_for_each().

template<typename Range , typename Function >

void tbb::parallel_for_each | ( | Range & | rng,
|  | const Function & | f,
|  | task_group_context & | context
| ) |  |

Calls function f for all items from rng using user-supplied context.

References tbb::parallel_for_each().

template<typename Range , typename Function >

void tbb::parallel_for_each | ( | const Range & | rng,
|  | const Function & | f,
|  | task_group_context & | context
| ) |  |

Calls function f for all items from const rng user-supplied context.

References tbb::parallel_for_each().

template<typename F0 , typename F1 , typename... F>

void tbb::parallel_invoke | ( | F0 && | f0,
|  | F1 && | f1,
|  | F &&... | f
| ) |  |

Executes a list of tasks in parallel and waits for all tasks to complete.

template<typename Range , typename Body >

void tbb::parallel_reduce | ( | const Range & | range,
|  | Body & | body
| ) |  |

Parallel iteration with reduction and default partitioner.

template<typename Range , typename Body >

void tbb::parallel_reduce | ( | const Range & | range,
|  | Body & | body,
|  | const simple_partitioner & | partitioner
| ) |  |

Parallel iteration with reduction and simple_partitioner.

template<typename Range , typename Body >

void tbb::parallel_reduce | ( | const Range & | range,
|  | Body & | body,
|  | const auto_partitioner & | partitioner
| ) |  |

Parallel iteration with reduction and auto_partitioner.

template<typename Range , typename Body >

void tbb::parallel_reduce | ( | const Range & | range,
|  | Body & | body,
|  | const static_partitioner & | partitioner
| ) |  |

Parallel iteration with reduction and static_partitioner.

template<typename Range , typename Body >

void tbb::parallel_reduce | ( | const Range & | range,
|  | Body & | body,
|  | affinity_partitioner & | partitioner
| ) |  |

Parallel iteration with reduction and affinity_partitioner.

template<typename Range , typename Body >

void tbb::parallel_reduce | ( | const Range & | range,
|  | Body & | body,
|  | const simple_partitioner & | partitioner,
|  | task_group_context & | context
| ) |  |

Parallel iteration with reduction, simple partitioner and user-supplied context.

template<typename Range , typename Body >

void tbb::parallel_reduce | ( | const Range & | range,
|  | Body & | body,
|  | const auto_partitioner & | partitioner,
|  | task_group_context & | context
| ) |  |

Parallel iteration with reduction, auto_partitioner and user-supplied context.

template<typename Range , typename Body >

void tbb::parallel_reduce | ( | const Range & | range,
|  | Body & | body,
|  | const static_partitioner & | partitioner,
|  | task_group_context & | context
| ) |  |

Parallel iteration with reduction, static_partitioner and user-supplied context.

template<typename Range , typename Body >

void tbb::parallel_reduce | ( | const Range & | range,
|  | Body & | body,
|  | affinity_partitioner & | partitioner,
|  | task_group_context & | context
| ) |  |

Parallel iteration with reduction, affinity_partitioner and user-supplied context.

template<typename Range , typename Value , typename RealBody , typename Reduction >

Value tbb::parallel_reduce | ( | const Range & | range,
|  | const Value & | identity,
|  | const RealBody & | real_body,
|  | const Reduction & | reduction
| ) |  |

Parallel iteration with reduction and default partitioner.

parallel_reduce overloads that work with anonymous function objects (see also requirements on parallel_reduce anonymous function objects).

template<typename Range , typename Value , typename RealBody , typename Reduction >

Value tbb::parallel_reduce | ( | const Range & | range,
|  | const Value & | identity,
|  | const RealBody & | real_body,
|  | const Reduction & | reduction,
|  | const simple_partitioner & | partitioner
| ) |  |

Parallel iteration with reduction and simple_partitioner.

template<typename Range , typename Value , typename RealBody , typename Reduction >

Value tbb::parallel_reduce | ( | const Range & | range,
|  | const Value & | identity,
|  | const RealBody & | real_body,
|  | const Reduction & | reduction,
|  | const auto_partitioner & | partitioner
| ) |  |

Parallel iteration with reduction and auto_partitioner.

template<typename Range , typename Value , typename RealBody , typename Reduction >

Value tbb::parallel_reduce | ( | const Range & | range,
|  | const Value & | identity,
|  | const RealBody & | real_body,
|  | const Reduction & | reduction,
|  | const static_partitioner & | partitioner
| ) |  |

Parallel iteration with reduction and static_partitioner.

template<typename Range , typename Value , typename RealBody , typename Reduction >

Value tbb::parallel_reduce | ( | const Range & | range,
|  | const Value & | identity,
|  | const RealBody & | real_body,
|  | const Reduction & | reduction,
|  | affinity_partitioner & | partitioner
| ) |  |

Parallel iteration with reduction and affinity_partitioner.

template<typename Range , typename Value , typename RealBody , typename Reduction >

Value tbb::parallel_reduce | ( | const Range & | range,
|  | const Value & | identity,
|  | const RealBody & | real_body,
|  | const Reduction & | reduction,
|  | const simple_partitioner & | partitioner,
|  | task_group_context & | context
| ) |  |

Parallel iteration with reduction, simple partitioner and user-supplied context.

template<typename Range , typename Value , typename RealBody , typename Reduction >

Value tbb::parallel_reduce | ( | const Range & | range,
|  | const Value & | identity,
|  | const RealBody & | real_body,
|  | const Reduction & | reduction,
|  | const auto_partitioner & | partitioner,
|  | task_group_context & | context
| ) |  |

Parallel iteration with reduction, auto_partitioner and user-supplied context.

template<typename Range , typename Value , typename RealBody , typename Reduction >

Value tbb::parallel_reduce | ( | const Range & | range,
|  | const Value & | identity,
|  | const RealBody & | real_body,
|  | const Reduction & | reduction,
|  | const static_partitioner & | partitioner,
|  | task_group_context & | context
| ) |  |

Parallel iteration with reduction, static_partitioner and user-supplied context.

template<typename Range , typename Value , typename RealBody , typename Reduction >

Value tbb::parallel_reduce | ( | const Range & | range,
|  | const Value & | identity,
|  | const RealBody & | real_body,
|  | const Reduction & | reduction,
|  | affinity_partitioner & | partitioner,
|  | task_group_context & | context
| ) |  |

Parallel iteration with reduction, affinity_partitioner and user-supplied context.

template<typename Range , typename Body >

void tbb::parallel_scan | ( | const Range & | range,
|  | Body & | body
| ) |  |

Parallel prefix with default partitioner.

template<typename Range , typename Body >

void tbb::parallel_scan | ( | const Range & | range,
|  | Body & | body,
|  | const simple_partitioner & | partitioner
| ) |  |

Parallel prefix with simple_partitioner.

template<typename Range , typename Body >

void tbb::parallel_scan | ( | const Range & | range,
|  | Body & | body,
|  | const auto_partitioner & | partitioner
| ) |  |

Parallel prefix with auto_partitioner.

template<typename RandomAccessIterator , typename Compare >

void tbb::parallel_sort | ( | RandomAccessIterator | begin,
|  | RandomAccessIterator | end,
|  | const Compare & | comp
| ) |  |

Sorts the data in [begin,end) using the given comparator.

The compare function object is used for all comparisons between elements during sorting. The compare object must define a bool operator() function.

Referenced by tbb::parallel_sort().

template<typename RandomAccessIterator >

void tbb::parallel_sort | ( | RandomAccessIterator | begin,
|  | RandomAccessIterator | end
| ) |  |

inline

Sorts the data in [begin,end) with a default comparator `std::less<RandomAccessIterator>`

References tbb::parallel_sort().

template<typename Range , typename Compare >

void tbb::parallel_sort | ( | Range & | rng,
|  | const Compare & | comp
| ) |  |

Sorts the data in rng using the given comparator.

References tbb::parallel_sort().

template<typename Range , typename Compare >

void tbb::parallel_sort | ( | const Range & | rng,
|  | const Compare & | comp
| ) |  |

Sorts the data in const rng using the given comparator.

References tbb::parallel_sort().

template<typename Range >

void tbb::parallel_sort | ( | Range & | rng) |  |

Sorts the data in rng with a default comparator `std::less<RandomAccessIterator>`

References tbb::parallel_sort().

template<typename Range >

void tbb::parallel_sort | ( | const Range & | rng) |  |

Sorts the data in const rng with a default comparator `std::less<RandomAccessIterator>`

References tbb::parallel_sort().

template<typename T >

void tbb::parallel_sort | ( | T * | begin,
|  | T * | end
| ) |  |

inline

Sorts the data in the range ``[begin,end) with a default comparator `std::less<T>`

References tbb::parallel_sort().

Copyright © 2005-2015 Intel Corporation. All Rights Reserved.

Intel, Pentium, Intel Xeon, Itanium, Intel XScale and VTune are registered trademarks or trademarks of Intel Corporation or its subsidiaries in the United States and other countries.

* Other names and brands may be claimed as the property of others.