Add __ldg

This commit is contained in:
streamhsa
2016-04-16 21:12:09 +08:00
parent f7089dbe4b
commit 0426564a7b
3 changed files with 159 additions and 0 deletions
+7
View File
@@ -401,6 +401,13 @@ __device__ int __all( int input);
__device__ int __any( int input);
__device__ unsigned long long int __ballot( int input);
// __ldg function
template <typename T>
__device__ __forceinline__ T __ldg( const T * addr)
{
return *addr;
}
// warp shuffle functions
#ifdef __cplusplus