Thrust
fill.h
Go to the documentation of this file.
1 /*
2  * Copyright 2008-2013 NVIDIA Corporation
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 
22 #pragma once
23 
24 #include <thrust/detail/config.h>
25 #include <thrust/detail/execution_policy.h>
26 
27 THRUST_NAMESPACE_BEGIN
28 
72 template<typename DerivedPolicy, typename ForwardIterator, typename T>
73 __host__ __device__
74  void fill(const thrust::detail::execution_policy_base<DerivedPolicy> &exec,
75  ForwardIterator first,
76  ForwardIterator last,
77  const T &value);
78 
79 
111 template<typename ForwardIterator, typename T>
112 __host__ __device__
113  void fill(ForwardIterator first,
114  ForwardIterator last,
115  const T &value);
116 
117 
154 template<typename DerivedPolicy, typename OutputIterator, typename Size, typename T>
155 __host__ __device__
156  OutputIterator fill_n(const thrust::detail::execution_policy_base<DerivedPolicy> &exec,
157  OutputIterator first,
158  Size n,
159  const T &value);
160 
161 
193 template<typename OutputIterator, typename Size, typename T>
194 __host__ __device__
195  OutputIterator fill_n(OutputIterator first,
196  Size n,
197  const T &value);
198 
199 
204 THRUST_NAMESPACE_END
205 
206 #include <thrust/detail/fill.inl>
__host__ __device__ void fill(ForwardIterator first, ForwardIterator last, const T &value)
__host__ __device__ OutputIterator fill_n(OutputIterator first, Size n, const T &value)