diff --git a/.gitattributes b/.gitattributes index 54ceef1f14c8b6c4229ac0fc215e72a244e27f24..0113b536332f708c3c7541cfe7173a0e7f26b52b 100644 --- a/.gitattributes +++ b/.gitattributes @@ -92,3 +92,4 @@ miniCUDA124/bin/nppist64_12.dll filter=lfs diff=lfs merge=lfs -text miniCUDA124/bin/nppig64_12.dll filter=lfs diff=lfs merge=lfs -text miniCUDA124/bin/ptxas.exe filter=lfs diff=lfs merge=lfs -text miniCUDA124/bin/nvprof.exe filter=lfs diff=lfs merge=lfs -text +miniCUDA124/bin/npps64_12.dll filter=lfs diff=lfs merge=lfs -text diff --git a/miniCUDA124/bin/npps64_12.dll b/miniCUDA124/bin/npps64_12.dll new file mode 100644 index 0000000000000000000000000000000000000000..549e0e6d5da11e87ffa266f9a981a1da78b1efda --- /dev/null +++ b/miniCUDA124/bin/npps64_12.dll @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:adca8a91eb74badd854caa136d4dc9d8a6da486ec251c9f6c698132722aa3a18 +size 12743168 diff --git a/miniCUDA124/include/thrust/detail/allocator/allocator_traits.h b/miniCUDA124/include/thrust/detail/allocator/allocator_traits.h new file mode 100644 index 0000000000000000000000000000000000000000..28ea728057da04b77f5ed7ede4201472dea1ef5a --- /dev/null +++ b/miniCUDA124/include/thrust/detail/allocator/allocator_traits.h @@ -0,0 +1,450 @@ +/* + * Copyright 2008-2018 NVIDIA Corporation + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +// allocator_traits::rebind_alloc and allocator::rebind_traits are from libc++, +// dual licensed under the MIT and the University of Illinois Open Source +// Licenses. + +#pragma once + +#include + +#if defined(_CCCL_IMPLICIT_SYSTEM_HEADER_GCC) +# pragma GCC system_header +#elif defined(_CCCL_IMPLICIT_SYSTEM_HEADER_CLANG) +# pragma clang system_header +#elif defined(_CCCL_IMPLICIT_SYSTEM_HEADER_MSVC) +# pragma system_header +#endif // no system header +#include +#include +#include +#include + +#include + +THRUST_NAMESPACE_BEGIN +namespace detail +{ + + +// forward declaration for has_member_system +template struct allocator_system; + + +namespace allocator_traits_detail +{ + +__THRUST_DEFINE_HAS_NESTED_TYPE(has_value_type, value_type) +__THRUST_DEFINE_HAS_NESTED_TYPE(has_pointer, pointer) +__THRUST_DEFINE_HAS_NESTED_TYPE(has_const_pointer, const_pointer) +__THRUST_DEFINE_HAS_NESTED_TYPE(has_reference, reference) +__THRUST_DEFINE_HAS_NESTED_TYPE(has_const_reference, const_reference) +__THRUST_DEFINE_HAS_NESTED_TYPE(has_void_pointer, void_pointer) +__THRUST_DEFINE_HAS_NESTED_TYPE(has_const_void_pointer, const_void_pointer) +__THRUST_DEFINE_HAS_NESTED_TYPE(has_difference_type, difference_type) +__THRUST_DEFINE_HAS_NESTED_TYPE(has_size_type, size_type) +__THRUST_DEFINE_HAS_NESTED_TYPE(has_propagate_on_container_copy_assignment, propagate_on_container_copy_assignment) +__THRUST_DEFINE_HAS_NESTED_TYPE(has_propagate_on_container_move_assignment, propagate_on_container_move_assignment) +__THRUST_DEFINE_HAS_NESTED_TYPE(has_propagate_on_container_swap, propagate_on_container_swap) +__THRUST_DEFINE_HAS_NESTED_TYPE(has_system_type, system_type) +__THRUST_DEFINE_HAS_NESTED_TYPE(has_is_always_equal, is_always_equal) +__THRUST_DEFINE_HAS_MEMBER_FUNCTION(has_member_system_impl, system) + +template + struct has_rebind +{ + typedef char yes_type; + typedef int no_type; + + template + static yes_type test(typename S::template rebind::other*); + template + static no_type test(...); + + static bool const value = sizeof(test(0)) == sizeof(yes_type); + + typedef thrust::detail::integral_constant type; +}; + +// The following fields of std::allocator have been deprecated (since C++17). +// There's no way to detect it other than explicit specialization. +#if THRUST_CPP_DIALECT >= 2017 +#define THRUST_SPECIALIZE_DEPRECATED(trait_name) \ +template \ +struct trait_name> : false_type {}; + +THRUST_SPECIALIZE_DEPRECATED(has_is_always_equal) +THRUST_SPECIALIZE_DEPRECATED(has_pointer) +THRUST_SPECIALIZE_DEPRECATED(has_const_pointer) +THRUST_SPECIALIZE_DEPRECATED(has_reference) +THRUST_SPECIALIZE_DEPRECATED(has_const_reference) + +#undef THRUST_SPECIALIZE_DEPRECATED + +template +struct has_rebind, U> : false_type {}; +#endif + +template + struct nested_pointer +{ + typedef typename T::pointer type; +}; + +template + struct nested_const_pointer +{ + typedef typename T::const_pointer type; +}; + +template + struct nested_reference +{ + typedef typename T::reference type; +}; + +template + struct nested_const_reference +{ + typedef typename T::const_reference type; +}; + +template + struct nested_void_pointer +{ + typedef typename T::void_pointer type; +}; + +template + struct nested_const_void_pointer +{ + typedef typename T::const_void_pointer type; +}; + +template + struct nested_difference_type +{ + typedef typename T::difference_type type; +}; + +template + struct nested_size_type +{ + typedef typename T::size_type type; +}; + +template + struct nested_propagate_on_container_copy_assignment +{ + typedef typename T::propagate_on_container_copy_assignment type; +}; + +template + struct nested_propagate_on_container_move_assignment +{ + typedef typename T::propagate_on_container_move_assignment type; +}; + +template + struct nested_propagate_on_container_swap +{ + typedef typename T::propagate_on_container_swap type; +}; + +template + struct nested_is_always_equal +{ + typedef typename T::is_always_equal type; +}; + +template + struct nested_system_type +{ + typedef typename T::system_type type; +}; + +template + struct has_member_system +{ + typedef typename allocator_system::type system_type; + + typedef typename has_member_system_impl::type type; + static const bool value = type::value; +}; + +template::value> + struct rebind_alloc +{ + typedef typename Alloc::template rebind::other type; +}; + +#if THRUST_CPP_DIALECT >= 2011 +template class Alloc, + typename T, typename... Args, typename U> + struct rebind_alloc, U, true> +{ + typedef typename Alloc::template rebind::other type; +}; + +template class Alloc, + typename T, typename... Args, typename U> + struct rebind_alloc, U, false> +{ + typedef Alloc type; +}; +#else // C++03 +template