Skip to content

Commit a6d41f6

Browse files
committed
Properly host-device qualify some previously unqualified functions.
Bug 2422333 Bug 2522259 Bug 2528822 Github NVIDIA#949 Github NVIDIA#973
1 parent 3af276e commit a6d41f6

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

thrust/detail/alignment.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -208,11 +208,13 @@ struct aligned_type;
208208
/// \p aligned_reinterpret_cast is responsible for ensuring that the alignment
209209
/// requirements are actually satisified.
210210
template <typename T, typename U>
211+
__host__ __device__
211212
T aligned_reinterpret_cast(U u)
212213
{
213214
return reinterpret_cast<T>(reinterpret_cast<void*>(u));
214215
}
215216

217+
__host__ __device__
216218
inline std::size_t aligned_storage_size(std::size_t n, std::size_t align)
217219
{
218220
return ((n + align - 1) / align) * align;

0 commit comments

Comments
 (0)