Bolt  1.3
C++ template library with support for OpenCL
reduce_by_key.h
Go to the documentation of this file.
1 /***************************************************************************
2 * © 2012,2014 Advanced Micro Devices, Inc. All rights reserved.
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 
16 ***************************************************************************/
17 
18 #if !defined( BOLT_AMP_REDUCE_BY_KEY_H )
19 #define BOLT_AMP_REDUCE_BY_KEY_H
20 #pragma once
21 
22 #include <bolt/amp/bolt.h>
23 #include <bolt/amp/pair.h>
24 #include "bolt/amp/scan.h"
25 
29 namespace bolt
30 {
31  namespace amp
32  {
33 
85  template<
86  typename InputIterator1,
87  typename InputIterator2,
88  typename OutputIterator1,
89  typename OutputIterator2>
92  control &ctl,
93  InputIterator1 keys_first,
94  InputIterator1 keys_last,
95  InputIterator2 values_first,
96  OutputIterator1 keys_output,
97  OutputIterator2 values_output);
98 
99  template<
100  typename InputIterator1,
101  typename InputIterator2,
102  typename OutputIterator1,
103  typename OutputIterator2>
106  InputIterator1 keys_first,
107  InputIterator1 keys_last,
108  InputIterator2 values_first,
109  OutputIterator1 keys_output,
110  OutputIterator2 values_output);
111 
154  template<
155  typename InputIterator1,
156  typename InputIterator2,
157  typename OutputIterator1,
158  typename OutputIterator2,
159  typename BinaryPredicate>
162  control &ctl,
163  InputIterator1 keys_first,
164  InputIterator1 keys_last,
165  InputIterator2 values_first,
166  OutputIterator1 keys_output,
167  OutputIterator2 values_output,
168  BinaryPredicate binary_pred);
169 
170  template<
171  typename InputIterator1,
172  typename InputIterator2,
173  typename OutputIterator1,
174  typename OutputIterator2,
175  typename BinaryPredicate>
178  InputIterator1 keys_first,
179  InputIterator1 keys_last,
180  InputIterator2 values_first,
181  OutputIterator1 keys_output,
182  OutputIterator2 values_output,
183  BinaryPredicate binary_pred);
184 
185 
229  template<
230  typename InputIterator1,
231  typename InputIterator2,
232  typename OutputIterator1,
233  typename OutputIterator2,
234  typename BinaryPredicate,
235  typename BinaryFunction>
238  control &ctl,
239  InputIterator1 keys_first,
240  InputIterator1 keys_last,
241  InputIterator2 values_first,
242  OutputIterator1 keys_output,
243  OutputIterator2 values_output,
244  BinaryPredicate binary_pred,
245  BinaryFunction binary_op);
246 
247  template<
248  typename InputIterator1,
249  typename InputIterator2,
250  typename OutputIterator1,
251  typename OutputIterator2,
252  typename BinaryPredicate,
253  typename BinaryFunction>
256  InputIterator1 keys_first,
257  InputIterator1 keys_last,
258  InputIterator2 values_first,
259  OutputIterator1 keys_output,
260  OutputIterator2 values_output,
261  BinaryPredicate binary_pred,
262  BinaryFunction binary_op);
263 
264  };// end of bolt::amp
265 };// end of bolt namespace
266 
267 #include <bolt/amp/detail/reduce_by_key.inl>
268 
269 #endif