Files
composable_kernel/composable_kernel/include/utility/integral_constant.hpp
Chao Liu 399be319a2 more utility code
[ROCm/composable_kernel commit: 7a7fe16086]
2019-09-09 00:29:33 -05:00

18 lines
439 B
C++

#ifndef CK_INTEGRAL_CONSTANT_HPP
#define CK_INTEGRAL_CONSTANT_HPP
namespace ck {
template <class T, T v>
struct integral_constant
{
static constexpr T value = v;
typedef T value_type;
typedef integral_constant type;
__host__ __device__ constexpr operator value_type() const noexcept { return value; }
__host__ __device__ constexpr value_type operator()() const noexcept { return value; }
};
} // namespace ck
#endif